From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#28542: Temporary failure in name resolution while quitting emacs Date: Mon, 30 Nov 2020 11:53:24 +0100 Message-ID: <87lfejcdzv.fsf@gnus.org> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24825"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 28542@debbugs.gnu.org To: Baylis Shanks Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Nov 30 11:54:10 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kjgos-0006LL-DR for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 30 Nov 2020 11:54:10 +0100 Original-Received: from localhost ([::1]:50522 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kjgor-0004uQ-EL for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 30 Nov 2020 05:54:09 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57966) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kjgok-0004uH-KS for bug-gnu-emacs@gnu.org; Mon, 30 Nov 2020 05:54:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42116) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kjgok-0004oc-Bg for bug-gnu-emacs@gnu.org; Mon, 30 Nov 2020 05:54:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kjgok-0006PD-Ag for bug-gnu-emacs@gnu.org; Mon, 30 Nov 2020 05:54:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 30 Nov 2020 10:54:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28542 X-GNU-PR-Package: emacs Original-Received: via spool by 28542-submit@debbugs.gnu.org id=B28542.160673361724586 (code B ref 28542); Mon, 30 Nov 2020 10:54:02 +0000 Original-Received: (at 28542) by debbugs.gnu.org; 30 Nov 2020 10:53:37 +0000 Original-Received: from localhost ([127.0.0.1]:53662 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjgoL-0006OU-1e for submit@debbugs.gnu.org; Mon, 30 Nov 2020 05:53:37 -0500 Original-Received: from quimby.gnus.org ([95.216.78.240]:34552) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjgoJ-0006OF-7C for 28542@debbugs.gnu.org; Mon, 30 Nov 2020 05:53:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=YUf57cAXpHZXjg/Z/avh+Vguykvw/GgISPmQq0jtt44=; b=uNuFyBgcwZX0Ge/UrYVBVmD3Ai aNKq7auNj9lkRiqJtv8nhIXDpuxBKMXokdQ3NgEzjs5BBR7+pu427fZAKAFnLAnBpE7p0XwkK16PJ mfmWVKFHkXd5qua/QKCP493eXHVkcSvpWzhK63i13VoK9/jFjZ/NRV8H+W6xHjnaD31Y=; Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kjgoA-0007wm-6g; Mon, 30 Nov 2020 11:53:28 +0100 X-Now-Playing: Lightning Bolt's _Sonic Citadel_: "Tom Thump" In-Reply-To: (Baylis Shanks's message of "Thu, 21 Sep 2017 17:13:59 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:194602 Archived-At: Baylis Shanks writes: > I had an http address open in a buffer (i think i closed that buffer), > and then i disconnected from the internet and then attempted to quit > emacs. Emacs would not quit; when i attempted to quit it, a message > involving 'open-network-stream' and 'temporary failure in name > resolution' would be displayed in *messages* and then nothing would > happen. > > Manually opening an elisp buffer and using setq to remove > save-place-kill-emacs-hook from kill-emacs-hook solved the problem. (This bug report unfortunately got no response at the time.) I'm guessing you don't have a backtrace here to let us see what the code in question was after all this time? > 2) more importantly, if there is an error in something called from > kill-emacs-hook, emacs should not just return to normal functioning > (without quitting), but rather should give the user a choice of > whether to continue to quit or not (if continue to quit is chosen, the > remaining items in kill-emacs-hook should be called). It's really > frustrating to a user when the user cannot figure out how to quit a > program. I agree. To reproduce: (push (lambda () (error "this is an error")) kill-emacs-hook) `C-x C-c' Result: Just an error message, and you can't kill Emacs. I think it should catch the error and ask whether to continue anyway. Opinions? The flow control here is a bit odd, though. `save-buffers-kill-emacs' calls Fkill_emacs, which starts: DEFUN ("kill-emacs", Fkill_emacs, Skill_emacs, 0, 1, "P", [...] /* Fsignal calls emacs_abort () if it sees that waiting_for_input is set. */ waiting_for_input = 0; if (noninteractive) safe_run_hooks (Qkill_emacs_hook); else run_hook (Qkill_emacs_hook); Is this bit done from the C level because of that waiting_for_input setting? And... I don't understand the comment -- the `error' (which calls signal?) doesn't abort Emacs? Anybody? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no