unsetenv the DISPLAY variable in the no_x11 flavor so that xdg-open

will not open URLs in a GUI browser
This commit is contained in:
robert
2023-11-12 18:09:22 +00:00
parent 39f4bc86b2
commit 6f8038386d
2 changed files with 16 additions and 1 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
COMMENT= GNU editor: extensible, customizable, self-documenting
VERSION= 29.1
REVISION= 0
REVISION= 1
DISTNAME= emacs-${VERSION}
CATEGORIES= editors
+15
View File
@@ -0,0 +1,15 @@
If !HAVE_X_WINDOWS unsetenv the DISPLAY variable so that
xdg-* tools will not open anything in a browser
Index: src/dispnew.c
--- src/dispnew.c.orig
+++ src/dispnew.c
@@ -6538,6 +6538,8 @@ init_display_interactive (void)
#endif
return;
}
+#else
+ (void)unsetenv ("DISPLAY");
#endif /* HAVE_X_WINDOWS */
#ifdef HAVE_NTGUI