[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#25778: 25.1; [PATCH] Drastically simplify xdg-open check

From: Vasilij Schneidermann
Subject: bug#25778: 25.1; [PATCH] Drastically simplify xdg-open check
Date: Fri, 17 Feb 2017 19:55:14 +0100
User-agent: Mutt/1.7.2 (2016-11-26)

> First, checking $DISPLAY doesn't yet mean you are in a GUI frame.  We
> have display-graphic-p for that.

The assumption that you need to be in a GUI frame is incorrect.  If I
run `emacs -nw` in a graphical terminal emulator, why would that prevent
me from opening a graphical browser?  The only way I see to detect
whether a graphical browser can be opened is by checking for X with

> And second, I don't understand what will happen with all the bugs
> mentioned in the comments if we remove the code that was supposed to
> avoid hitting them.  Maybe I'm missing something obvious.

OK, I'll go through them all for completeness' sake:

- bug#7166: This one arises from using /bin/sh in combination with
  `nohup` for launching xdg-open, resulting in a lack of shell quoting.
  As `xdg-open` is launched directly, it's no longer relevant and only
  mentioned because of `nohup` (which is no longer used either).
- bug#8917: The old usage of `call-process` has made `nohup` obsolete.
  Irrelevant as `nohup` isn't used any longer.
- bug#9779: Extension of the now removed xdg-open DE detection logic,
  together with some discussion whether nohup is still necessary.  Some
  voices in favor of not doing any unnecessary detection.
- The linked emacs-devel thread: Sighting of a possible bug in
  gnome-open.  As `nohup` is no longer used, there's no way this could
  have been worked around with its usage

Summary: All linked bugs are related to `nohup` which is only checked
for, but not actually used.  Therefore they can be disregarded.

Do you have any actual objections based on a situation where one would
*not* want to use xdg-open, even though it's installed and the user in a
X11 session?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]