From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#25778: 25.1; [PATCH] Drastically simplify xdg-open check Date: Sat, 18 Feb 2017 09:58:18 +0200 Message-ID: <83r32wq6at.fsf@gnu.org> References: <83shncr7bh.fsf@gnu.org> <20170217185514.GA599@odonien.localdomain> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1487404754 8007 195.159.176.226 (18 Feb 2017 07:59:14 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 18 Feb 2017 07:59:14 +0000 (UTC) Cc: 25778@debbugs.gnu.org To: Vasilij Schneidermann Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Feb 18 08:59:09 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cezv8-0001OA-Sv for geb-bug-gnu-emacs@m.gmane.org; Sat, 18 Feb 2017 08:59:07 +0100 Original-Received: from localhost ([::1]:57501 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cezvE-0003vm-KM for geb-bug-gnu-emacs@m.gmane.org; Sat, 18 Feb 2017 02:59:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59736) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cezv8-0003vP-Oi for bug-gnu-emacs@gnu.org; Sat, 18 Feb 2017 02:59:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cezv3-0006Yq-Uv for bug-gnu-emacs@gnu.org; Sat, 18 Feb 2017 02:59:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:45906) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cezv3-0006Yk-Qx for bug-gnu-emacs@gnu.org; Sat, 18 Feb 2017 02:59:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cezv3-0001iK-JU for bug-gnu-emacs@gnu.org; Sat, 18 Feb 2017 02:59:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 18 Feb 2017 07:59:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25778 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 25778-submit@debbugs.gnu.org id=B25778.14874046846524 (code B ref 25778); Sat, 18 Feb 2017 07:59:01 +0000 Original-Received: (at 25778) by debbugs.gnu.org; 18 Feb 2017 07:58:04 +0000 Original-Received: from localhost ([127.0.0.1]:44105 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cezu8-0001hA-7r for submit@debbugs.gnu.org; Sat, 18 Feb 2017 02:58:04 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:40346) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cezu6-0001gg-IU for 25778@debbugs.gnu.org; Sat, 18 Feb 2017 02:58:02 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cezty-0005uS-7A for 25778@debbugs.gnu.org; Sat, 18 Feb 2017 02:57:57 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:42542) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cezty-0005uC-3V; Sat, 18 Feb 2017 02:57:54 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4523 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ceztu-0002fR-Kq; Sat, 18 Feb 2017 02:57:52 -0500 In-reply-to: <20170217185514.GA599@odonien.localdomain> (message from Vasilij Schneidermann on Fri, 17 Feb 2017 19:55:14 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:129477 Archived-At: > Date: Fri, 17 Feb 2017 19:55:14 +0100 > From: Vasilij Schneidermann > Cc: 25778@debbugs.gnu.org > > > 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 > $DISPLAY. In that case, maybe we shouldn't test $DISPLAY at all? Why restrict this to X if xdg-open is already tested for availability? > 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? See Glenn's response about that. I think we should be more careful with these issues, and at least do some more research of them before we can be sure they are no longer relevant. If you could follow up on that, it would be great. Thanks.