From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#21723: 24.5; Bug in `server-kill-emacs-query-function' Date: Wed, 21 Oct 2015 19:51:59 +0300 Message-ID: <83si54upu8.fsf@gnu.org> References: <22055.21041.100895.444472@lambda.ccs.neu.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1445491300 24863 80.91.229.3 (22 Oct 2015 05:21:40 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 22 Oct 2015 05:21:40 +0000 (UTC) Cc: 21723-done@debbugs.gnu.org To: Eli Barzilay Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Oct 22 07:21:29 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Zp8Jb-0006vH-Py for geb-bug-gnu-emacs@m.gmane.org; Thu, 22 Oct 2015 07:21:27 +0200 Original-Received: from localhost ([::1]:55891 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zp8Jb-00048q-6W for geb-bug-gnu-emacs@m.gmane.org; Thu, 22 Oct 2015 01:21:27 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51902) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZowdS-0001MF-7X for bug-gnu-emacs@gnu.org; Wed, 21 Oct 2015 12:53:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZowdK-0003IS-EJ for bug-gnu-emacs@gnu.org; Wed, 21 Oct 2015 12:53:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:40673) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZowdK-0003I9-Ad for bug-gnu-emacs@gnu.org; Wed, 21 Oct 2015 12:53:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZowdK-0004ku-94 for bug-gnu-emacs@gnu.org; Wed, 21 Oct 2015 12:53:02 -0400 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Wed, 21 Oct 2015 16:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 21723 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Mail-Followup-To: 21723@debbugs.gnu.org, eliz@gnu.org, eli@barzilay.org Original-Received: via spool by 21723-done@debbugs.gnu.org id=D21723.144544632418194 (code D ref 21723); Wed, 21 Oct 2015 16:53:01 +0000 Original-Received: (at 21723-done) by debbugs.gnu.org; 21 Oct 2015 16:52:04 +0000 Original-Received: from localhost ([127.0.0.1]:59613 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZowcN-0004jN-P3 for submit@debbugs.gnu.org; Wed, 21 Oct 2015 12:52:04 -0400 Original-Received: from mtaout28.012.net.il ([80.179.55.184]:44693) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZowcL-0004iw-DE for 21723-done@debbugs.gnu.org; Wed, 21 Oct 2015 12:52:02 -0400 Original-Received: from conversion-daemon.mtaout28.012.net.il by mtaout28.012.net.il (HyperSendmail v2007.08) id <0NWK00N00XDN1Q00@mtaout28.012.net.il> for 21723-done@debbugs.gnu.org; Wed, 21 Oct 2015 19:51:09 +0300 (IDT) Original-Received: from HOME-C4E4A596F7 ([84.94.185.246]) by mtaout28.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NWK00GFJXH9ZR60@mtaout28.012.net.il>; Wed, 21 Oct 2015 19:51:09 +0300 (IDT) In-reply-to: <22055.21041.100895.444472@lambda.ccs.neu.edu> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x 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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:107822 Archived-At: > From: Eli Barzilay > Date: Wed, 21 Oct 2015 04:52:01 -0400 > > The code in `server-kill-emacs-query-function' (in server.el) has this > in an `or': > > (let (live-client) > (dolist (proc server-clients) > (when (memq t (mapcar 'buffer-live-p (process-get > proc 'buffers))) > (setq live-client t))) > live-client) > > IIUC, this looks for a live client, and if there is one, the t result > means that the yes-or-no-p question in the end will *not* get asked. > I verified this by: > > * Starting emacs -Q and in it start the server > > * Run emacsclient on a random file > > * Now, C-x C-c exits without asking any questions. > > It seems to me like that condition is reversed, an the last line > should instead be: (not live-client) Ouch! This bug was there for almost 10 years, since the simple loop was rewritten as dolist, and the negation of the result was dropped in the process. Should be fixed now, thanks.