From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Alan Mackenzie , 1226@debbugs.gnu.org Resent-From: Alan Mackenzie Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Wed, 22 Oct 2008 10:05:05 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@emacsbugs.donarmstrong.com id=B.12246694682997 (code B ref -1); Wed, 22 Oct 2008 10:05:05 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-7.0 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 22 Oct 2008 09:57:48 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9M9vicI002991 for ; Wed, 22 Oct 2008 02:57:46 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KsaTI-0003D5-35 for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KsaTH-0003Cp-1L for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:43 -0400 Received: from [199.232.76.173] (port=56870 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KsaTG-0003Cm-LH for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:42 -0400 Received: from colin.muc.de ([193.149.48.1]:1632 helo=mail.muc.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KsaTG-0006m4-EQ for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:42 -0400 Received: (qmail 43226 invoked by uid 3782); 22 Oct 2008 09:57:40 -0000 Received: from acm.muc.de (pD9E5206A.dip.t-dialin.net [217.229.32.106]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Wed, 22 Oct 2008 11:57:39 +0200 Received: (qmail 3818 invoked by uid 1000); 22 Oct 2008 10:07:13 -0000 Date: Wed, 22 Oct 2008 10:07:13 +0000 To: bug-gnu-emacs@gnu.org Message-ID: <20081022100713.GC924@muc.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-detected-operating-system: by monty-python.gnu.org: FreeBSD 4.6-4.9 (i) With desktop enabled, start emacs. (ii) Start a second emacs session. Emacs2 detects Emacs1 and the danger of contention over .emacs.desktop. It prompts thusly: "Warning: desktop file appears to be in use by PID 3616. Using it may cause conflicts. Use it anyway? (y or n)" (iii) Type n. (iv) Attempt C-c C-x. Emacs2 decides, because desktop is "enabled", that it wants to save a desktop file, and prompts: "Directory for desktop file: ~/" At this point, C-g aborts the "end Emacs" command. One now has the unpleasant choice of killing Emacs2 from the (operating system) console or typing in some random directory to dump the empty .emacs.desktop to. This is a bug. Even worse, accepting the prompt's default directory, ~/, might overwrite the real .emacs.desktop. -- Alan Mackenzie (Nuremberg, Germany). From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Lawrence Mitchell , 1226@debbugs.gnu.org Resent-From: Lawrence Mitchell Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Wed, 22 Oct 2008 11:20:02 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.122467397022092 (code B ref 1226); Wed, 22 Oct 2008 11:20:02 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-10.9 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER,RCVD_IN_DNSWL_MED,X_DEBBUGS_NO_ACK autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 22 Oct 2008 11:12:50 +0000 Received: from nougat.ucs.ed.ac.uk (nougat.ucs.ed.ac.uk [129.215.13.205]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9MBCenl022086 for <1226@emacsbugs.donarmstrong.com>; Wed, 22 Oct 2008 04:12:42 -0700 Received: from wrath.ph.ed.ac.uk (wrath.ph.ed.ac.uk [129.215.73.7]) by nougat.ucs.ed.ac.uk (8.13.8/8.13.4) with ESMTP id m9MBCTlF022978; Wed, 22 Oct 2008 12:12:29 +0100 (BST) Received: from lamacq.ph.ed.ac.uk (lamacq.ph.ed.ac.uk [129.215.72.156]) by wrath.ph.ed.ac.uk (8.13.8/8.12.10) with ESMTP id m9MBCTrB031722; Wed, 22 Oct 2008 12:12:29 +0100 Received: from lamacq.ph.ed.ac.uk (localhost.localdomain [127.0.0.1]) by lamacq.ph.ed.ac.uk (8.13.8/8.12.10) with ESMTP id m9MBCTlN031901; Wed, 22 Oct 2008 12:12:29 +0100 Received: (from s0198183@localhost) by lamacq.ph.ed.ac.uk (8.13.8/8.13.8/Submit) id m9MBCTFn031898; Wed, 22 Oct 2008 12:12:29 +0100 X-Authentication-Warning: lamacq.ph.ed.ac.uk: s0198183 set sender to lawrence.mitchell@ed.ac.uk using -f From: Lawrence Mitchell To: Alan Mackenzie Cc: 1226@debbugs.gnu.org Organization: me References: <20081022100713.GC924@muc.de> Date: Wed, 22 Oct 2008 12:12:28 +0100 In-Reply-To: <20081022100713.GC924@muc.de> (Alan Mackenzie's message of "Wed, 22 Oct 2008 10:07:13 +0000") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Edinburgh-Scanned: at nougat.ucs.ed.ac.uk with MIMEDefang 2.60, Sophie, Sophos Anti-Virus, Clam AntiVirus X-Scanned-By: MIMEDefang 2.60 on 129.215.13.205 Alan Mackenzie wrote: > (i) With desktop enabled, start emacs. > (ii) Start a second emacs session. > Emacs2 detects Emacs1 and the danger of contention over .emacs.desktop. > It prompts thusly: > "Warning: desktop file appears to be in use by PID 3616. > Using it may cause conflicts. Use it anyway? (y or n)" > (iii) Type n. > (iv) Attempt C-c C-x. > Emacs2 decides, because desktop is "enabled", that it wants to save a > desktop file, and prompts: > "Directory for desktop file: ~/" > At this point, C-g aborts the "end Emacs" command. One now has the > unpleasant choice of killing Emacs2 from the (operating system) console > or typing in some random directory to dump the empty .emacs.desktop to. > This is a bug. I cannot reproduce with the following sequence to enable desktop: ;; start an emacs that creates a desktop file and quit $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) (desktop-save-mode 1) (desktop-read) (dired "/tmp/") (save-buffers-kill-emacs))' ;; now start an emacs to read the desktop file (acquiring a lock) $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) (desktop-save-mode 1) (desktop-read))' & ;; start a second emacs $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) (desktop-save-mode 1) (desktop-read))' ;; This one prompts Warning: desktop file appears to be in use by PID XXXXX. Using it may cause conflicts. Use it anyway? (y or n) ;; I answer "n", the desktop file is not loaded. ;; Now I do save-buffers-kill-emacs and am asked: Save desktop? (y or n) ;; I hit "n", the desktop is not saved and Emacs quits as expected. How have you enabled desktop in your emacs session to produce this problem? -- Lawrence Mitchell From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Alan Mackenzie , 1226@debbugs.gnu.org Resent-From: Alan Mackenzie Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Wed, 22 Oct 2008 12:45:02 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.122467914110971 (code B ref 1226); Wed, 22 Oct 2008 12:45:02 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.5 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 22 Oct 2008 12:39:01 +0000 Received: from mail.muc.de (qmailr@colin.muc.de [193.149.48.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9MCcrXL010954 for <1226@emacsbugs.donarmstrong.com>; Wed, 22 Oct 2008 05:38:55 -0700 Received: (qmail 94565 invoked by uid 3782); 22 Oct 2008 12:38:52 -0000 Received: from acm.muc.de (pD9E5206A.dip.t-dialin.net [217.229.32.106]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Wed, 22 Oct 2008 14:38:49 +0200 Received: (qmail 6105 invoked by uid 1000); 22 Oct 2008 12:48:24 -0000 Date: Wed, 22 Oct 2008 12:48:23 +0000 To: Lawrence Mitchell Cc: 1226@debbugs.gnu.org Message-ID: <20081022124823.GD924@muc.de> References: <20081022100713.GC924@muc.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) From: Alan Mackenzie X-Primary-Address: acm@muc.de On Wed, Oct 22, 2008 at 12:12:28PM +0100, Lawrence Mitchell wrote: > Alan Mackenzie wrote: > > (i) With desktop enabled, start emacs. > > (ii) Start a second emacs session. [ .... ] > > Emacs2 decides, because desktop is "enabled", that it wants to save a > > desktop file, and prompts: > > "Directory for desktop file: ~/" > > At this point, C-g aborts the "end Emacs" command. One now has the > > unpleasant choice of killing Emacs2 from the (operating system) console > > or typing in some random directory to dump the empty .emacs.desktop to. > > This is a bug. > I cannot reproduce with the following sequence to enable desktop: > ;; start an emacs that creates a desktop file and quit > $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) > (desktop-save-mode 1) (desktop-read) (dired "/tmp/") > (save-buffers-kill-emacs))' > ;; now start an emacs to read the desktop file (acquiring a lock) > $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) > (desktop-save-mode 1) (desktop-read))' & > ;; start a second emacs > $ emacs -Q --eval '(progn (setq desktop-path (list "/tmp/")) > (desktop-save-mode 1) (desktop-read))' > ;; This one prompts > Warning: desktop file appears to be in use by PID XXXXX. > Using it may cause conflicts. Use it anyway? (y or n) > ;; I answer "n", the desktop file is not loaded. > ;; Now I do save-buffers-kill-emacs and am asked: > Save desktop? (y or n) > ;; I hit "n", the desktop is not saved and Emacs quits as > expected. > How have you enabled desktop in your emacs session to produce > this problem? Sorry, I should have said this. With a .emacs containing exactly one line: (desktop-save-mode 1) and with no existing .emacs.desktop, I started Emacs, visited two files, did M-x desktop-save, and exited Emacs. Then I started, successively, two Emacs sessions like this: /path/to/emacs --no-site-file , where the emacs was a CVS version from last night. I tried this (i) on two Linux tty's; (ii) From an X-Windows (GNOME) terminal, > Lawrence Mitchell -- Alan Mackenzie (Nuremberg, Germany). From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Glenn Morris , 1226@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Thu, 23 Oct 2008 01:25:05 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.12247245156310 (code B ref 1226); Thu, 23 Oct 2008 01:25:05 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-11.8 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER,RCVD_IN_DNSWL_MED,X_DEBBUGS_NO_ACK autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 23 Oct 2008 01:15:15 +0000 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9N1FCUV006222 for <1226@emacsbugs.donarmstrong.com>; Wed, 22 Oct 2008 18:15:13 -0700 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1KsokX-0005bU-52; Wed, 22 Oct 2008 21:12:29 -0400 From: Glenn Morris To: Alan Mackenzie Cc: 1226@debbugs.gnu.org References: <20081022100713.GC924@muc.de> X-Spook: Indigo $400 million in gold bullion Dick Cheney brigand X-Ran: mpxzl]~N:F+T]_&eHw0E+NN}5;}av+CL!=dA X-Hue: yellow X-Attribution: GM Date: Wed, 22 Oct 2008 21:12:29 -0400 In-Reply-To: <20081022100713.GC924@muc.de> (Alan Mackenzie's message of "Wed, 22 Oct 2008 10:07:13 +0000") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Alan Mackenzie wrote: > At this point, C-g aborts the "end Emacs" command. One now has the > unpleasant choice of killing Emacs2 from the (operating system) console > or typing in some random directory to dump the empty .emacs.desktop to. Another choice is of course just to turn off desktop-save-mode, then exit. > This is a bug. What should it do instead? i) Not turn on desktop-save-mode if you answer no to the initial question: "Warning: desktop file appears to be in use by PID 3616. Using it may cause conflicts. Use it anyway? (y or n)" ii) Or should this question offer a third alternative, eg "(q) - disable desktop-save-mode for this session"? iii) Or should the prompt Directory for desktop file: ~/" somehow offer an option to turn off desktop-save-mode? iv) Something else? > Even worse, accepting the prompt's default directory, ~/, might > overwrite the real .emacs.desktop. If you try it, you will find you get adequate warning about overwriting the existing desktop. From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Glenn Morris , 1226@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Thu, 23 Oct 2008 01:25:06 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.12247247146695 (code B ref 1226); Thu, 23 Oct 2008 01:25:06 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-11.8 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER,RCVD_IN_DNSWL_MED,X_DEBBUGS_NO_ACK autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 23 Oct 2008 01:18:34 +0000 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9N1IVfO006689 for <1226@emacsbugs.donarmstrong.com>; Wed, 22 Oct 2008 18:18:32 -0700 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1Ksonl-0005h6-3E; Wed, 22 Oct 2008 21:15:49 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18687.53316.955355.102526@fencepost.gnu.org> Date: Wed, 22 Oct 2008 21:15:48 -0400 From: Glenn Morris To: Alan Mackenzie , 1226@debbugs.gnu.org In-Reply-To: References: <20081022100713.GC924@muc.de> X-Attribution: GM X-Mailer: VM (www.wonderworks.com/vm), GNU Emacs (www.gnu.org/software/emacs) X-Hue: cyan X-Ran: y{c7/YebR[>30t#JxC'5]K5M!w{pzbEzTzwn}yJyRh}[@wL%3Z1`eB$Z0&}(~&sL+2QJNG Glenn Morris wrote (on Wed, 22 Oct 2008 at 21:12 -0400): > If you try it, you will find you get adequate warning about overwriting > the existing desktop. And if you answer "no" to the prompt about overwriting, Emacs exits without saving the desktop (admittedly, perhaps a slightly obscure way to get this functionality). So I don't see that you are being held hostage here. From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Alan Mackenzie , 1226@debbugs.gnu.org Resent-From: Alan Mackenzie Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Thu, 23 Oct 2008 09:35:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.122475414131597 (code B ref 1226); Thu, 23 Oct 2008 09:35:03 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.5 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 23 Oct 2008 09:29:01 +0000 Received: from mail.muc.de (qmailr@colin.muc.de [193.149.48.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9N9SsMu031591 for <1226@emacsbugs.donarmstrong.com>; Thu, 23 Oct 2008 02:28:56 -0700 Received: (qmail 59510 invoked by uid 3782); 23 Oct 2008 09:28:53 -0000 Received: from acm.muc.de (pD9E53152.dip.t-dialin.net [217.229.49.82]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Thu, 23 Oct 2008 11:28:52 +0200 Received: (qmail 3230 invoked by uid 1000); 23 Oct 2008 09:38:32 -0000 Date: Thu, 23 Oct 2008 09:38:32 +0000 To: Glenn Morris Cc: 1226@debbugs.gnu.org Message-ID: <20081023093832.GD2666@muc.de> References: <20081022100713.GC924@muc.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) From: Alan Mackenzie X-Primary-Address: acm@muc.de Hi, Glenn! On Wed, Oct 22, 2008 at 09:12:29PM -0400, Glenn Morris wrote: > Alan Mackenzie wrote: > > At this point, C-g aborts the "end Emacs" command. One now has the > > unpleasant choice of killing Emacs2 from the (operating system) > > console or typing in some random directory to dump the empty > > .emacs.desktop to. > Another choice is of course just to turn off desktop-save-mode, then > exit. I suppose so. You have to have a cool head to think of this, though. > > This is a bug. > What should it do instead? > i) Not turn on desktop-save-mode if you answer no to the initial > question: > "Warning: desktop file appears to be in use by PID 3616. > Using it may cause conflicts. Use it anyway? (y or n)" > ii) Or should this question offer a third alternative, eg "(q) - > disable desktop-save-mode for this session"? > iii) Or should the prompt > Directory for desktop file: ~/" > somehow offer an option to turn off desktop-save-mode? > iv) Something else? I think Lawrence Mitchell's suggestion of what should happen is right: first prompt "save desktop (y/n): ", and after getting a y, prompt for a directory to save in. > > Even worse, accepting the prompt's default directory, ~/, might > > overwrite the real .emacs.desktop. > If you try it, you will find you get adequate warning about overwriting > the existing desktop. OK. -- Alan Mackenzie (Nuremberg, Germany). From unknown Sun Aug 17 01:55:39 2025 X-Loop: don@donarmstrong.com Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Reply-To: Glenn Morris , 1226@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Thu, 23 Oct 2008 19:35:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1226 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 1226-submit@emacsbugs.donarmstrong.com id=B1226.122479008427881 (code B ref 1226); Thu, 23 Oct 2008 19:35:03 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-11.8 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, HAS_BUG_NUMBER,RCVD_IN_DNSWL_MED,X_DEBBUGS_NO_ACK autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1226) by emacsbugs.donarmstrong.com; 23 Oct 2008 19:28:04 +0000 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9NJS0c2027875 for <1226@emacsbugs.donarmstrong.com>; Thu, 23 Oct 2008 12:28:02 -0700 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1Kt5o2-0005xe-N5; Thu, 23 Oct 2008 15:25:14 -0400 From: Glenn Morris To: Alan Mackenzie Cc: 1226@debbugs.gnu.org References: <20081022100713.GC924@muc.de> <20081023093832.GD2666@muc.de> X-Spook: John Kerry encryption Majic World Trade Center Sears X-Ran: 7Ss/SCZI(gJ�&fc>EMA+]aFP'M(aVKdq8$0UaR`xWo%m{t$k(s|%`gY*)pLgx+F8eeVB X-Hue: cyan X-Attribution: GM Date: Thu, 23 Oct 2008 15:25:14 -0400 In-Reply-To: <20081023093832.GD2666@muc.de> (Alan Mackenzie's message of "Thu, 23 Oct 2008 09:38:32 +0000") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Alan Mackenzie wrote: > I think Lawrence Mitchell's suggestion of what should happen is right: > first prompt "save desktop (y/n): ", and after getting a y, prompt for a > directory to save in. It sounds like you want the variable desktop-save to have another option: ask-if-old -- ask if desktop file exists, otherwise just save. Or perhaps one of the existing ask, ask-if-exists options? From rgm@gnu.org Wed Feb 25 19:57:27 2009 Received: (at control) by emacsbugs.donarmstrong.com; 26 Feb 2009 03:57:27 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-2.0 required=4.0 tests=VALID_BTS_CONTROL autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n1Q3vL63009075 for ; Wed, 25 Feb 2009 19:57:23 -0800 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1LcXKz-00072r-09; Wed, 25 Feb 2009 22:55:05 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18854.4760.940911.972299@fencepost.gnu.org> Date: Wed, 25 Feb 2009 22:55:04 -0500 From: Glenn Morris To: control Subject: control message reassign 686 emacs,w32 reassign 1780 emacsbugs.donarmstrong.com severity 2473 wishlist reassign 2468 spam reassign 2469 spam reassign 2471 spam severity 2474 wishlist severity 973 wishlist tags 846 wontfix reassign 1131 emacs,ns severity 1226 minor severity 1253 minor severity 1339 minor tags 1339 moreinfo severity 1474 wishlist severity 1582 minor severity 1646 minor tags 1753 moreinfo reassign 2475 spam From unknown Sun Aug 17 01:55:39 2025 X-Loop: help-debbugs@gnu.org Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Resent-From: Juanma Barranquero Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 06 Jul 2011 02:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 1226 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Alan Mackenzie Cc: Glenn Morris , 1226@debbugs.gnu.org Received: via spool by 1226-submit@debbugs.gnu.org id=B1226.130991815619038 (code B ref 1226); Wed, 06 Jul 2011 02:10:02 +0000 Received: (at 1226) by debbugs.gnu.org; 6 Jul 2011 02:09:16 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QeHYC-0004x1-Cl for submit@debbugs.gnu.org; Tue, 05 Jul 2011 22:09:16 -0400 Received: from mail-qw0-f44.google.com ([209.85.216.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QeHYA-0004wq-SQ for 1226@debbugs.gnu.org; Tue, 05 Jul 2011 22:09:15 -0400 Received: by qwc23 with SMTP id 23so3240734qwc.3 for <1226@debbugs.gnu.org>; Tue, 05 Jul 2011 19:09:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=d/cFzTxGDi91CI+IfE7HccL3zkmL1ADAa58my9OdwZI=; b=fHHsQqStxa2JTR/5g67vhrJGco2lWBDdGu6yL9QnxiwixhtTzj5r2a3vFFlziTMltv RKh0Qo6np2kAOvP0lkwMDqZtYHcbgEkojamAv4ecqVFAE7LF1tKWVjeB3jmvVqzaBYVY pUKnkigqbBJ3tFYRIBynpFJlPXtIyigvyqZns= Received: by 10.229.215.202 with SMTP id hf10mr3810212qcb.212.1309918149270; Tue, 05 Jul 2011 19:09:09 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.40.131 with HTTP; Tue, 5 Jul 2011 19:08:29 -0700 (PDT) In-Reply-To: <20081023093832.GD2666@muc.de> References: <20081022100713.GC924@muc.de> <20081023093832.GD2666@muc.de> From: Juanma Barranquero Date: Wed, 6 Jul 2011 04:08:29 +0200 Message-ID: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.8 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) On Thu, Oct 23, 2008 at 11:38, Alan Mackenzie wrote: > I think Lawrence Mitchell's suggestion of what should happen is right: > first prompt "save desktop (y/n): ", and after getting a y, prompt for a > directory to save in. This is the behavior after revno:100049, I think. Could you please check whether it does work as expected? =C2=A0 =C2=A0 Juanma From unknown Sun Aug 17 01:55:39 2025 X-Loop: help-debbugs@gnu.org Subject: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Resent-From: Alan Mackenzie Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 08 Jul 2011 20:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 1226 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Juanma Barranquero Cc: Glenn Morris , 1226@debbugs.gnu.org Received: via spool by 1226-submit@debbugs.gnu.org id=B1226.131015821618224 (code B ref 1226); Fri, 08 Jul 2011 20:51:02 +0000 Received: (at 1226) by debbugs.gnu.org; 8 Jul 2011 20:50:16 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QfI07-0004jt-4H for submit@debbugs.gnu.org; Fri, 08 Jul 2011 16:50:15 -0400 Received: from colin.muc.de ([193.149.48.1] helo=mail.muc.de) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QfI04-0004jc-Rp for 1226@debbugs.gnu.org; Fri, 08 Jul 2011 16:50:13 -0400 Received: (qmail 18325 invoked by uid 3782); 8 Jul 2011 20:50:06 -0000 Received: from acm.muc.de (pD951970C.dip.t-dialin.net [217.81.151.12]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Fri, 08 Jul 2011 22:50:04 +0200 Received: (qmail 5320 invoked by uid 1000); 8 Jul 2011 20:48:00 -0000 Date: Fri, 8 Jul 2011 20:48:00 +0000 Message-ID: <20110708204800.GA2351@acm.acm> References: <20081022100713.GC924@muc.de> <20081023093832.GD2666@muc.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: -1.6 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.6 (-) Hi, Juanma, On Wed, Jul 06, 2011 at 04:08:29AM +0200, Juanma Barranquero wrote: > On Thu, Oct 23, 2008 at 11:38, Alan Mackenzie wrote: > > I think Lawrence Mitchell's suggestion of what should happen is right: > > first prompt "save desktop (y/n): ", and after getting a y, prompt for a > > directory to save in. > This is the behavior after revno:100049, I think. Could you please > check whether it does work as expected? That's perfect! Thanks. >     Juanma -- Alan Mackenzie (Nuremberg, Germany). From unknown Sun Aug 17 01:55:39 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.427 (Entity 5.427) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Alan Mackenzie Subject: bug#1226: closed (Re: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly.) Message-ID: References: <20081022100713.GC924@muc.de> X-Gnu-PR-Message: they-closed 1226 X-Gnu-PR-Package: emacs Reply-To: 1226@debbugs.gnu.org Date: Fri, 08 Jul 2011 23:19:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1310167142-3463-1" This is a multi-part message in MIME format... ------------=_1310167142-3463-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work pro= perly. which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 1226@debbugs.gnu.org. --=20 1226: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D1226 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1310167142-3463-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 1226-done) by debbugs.gnu.org; 8 Jul 2011 23:18:50 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QfKJu-0000tO-4q for submit@debbugs.gnu.org; Fri, 08 Jul 2011 19:18:50 -0400 Received: from mail-pv0-f172.google.com ([74.125.83.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QfKJt-0000tC-3R for 1226-done@debbugs.gnu.org; Fri, 08 Jul 2011 19:18:49 -0400 Received: by pvh18 with SMTP id 18so1567639pvh.3 for <1226-done@debbugs.gnu.org>; Fri, 08 Jul 2011 16:18:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=4I5wV4CpoKnuNxGi2IX1TdhGYw3/9L7lvqwkG32Gqko=; b=ReuYRnirs3kYirlsLTS5F96phL3gT+DYdniQBghpudWhRz16mfjiR3U+B1yhIh36rB mnn9Ibonc0nfrbxBI6RY1TZb2oftkxwficGus0tDbfJN5n77FJV0y7aMY5eAyJOx8wV5 S5OJMqWLYgiQswDHCpnM0jwupmyQ9U9ApA89g= Received: by 10.143.97.26 with SMTP id z26mr539119wfl.81.1310167123114; Fri, 08 Jul 2011 16:18:43 -0700 (PDT) MIME-Version: 1.0 Received: by 10.142.144.4 with HTTP; Fri, 8 Jul 2011 16:18:03 -0700 (PDT) In-Reply-To: <20110708204800.GA2351@acm.acm> References: <20081022100713.GC924@muc.de> <20081023093832.GD2666@muc.de> <20110708204800.GA2351@acm.acm> From: Juanma Barranquero Date: Sat, 9 Jul 2011 01:18:03 +0200 Message-ID: Subject: Re: bug#1226: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. To: Alan Mackenzie Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.9 (--) X-Debbugs-Envelope-To: 1226-done Cc: Glenn Morris , 1226-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.9 (--) On Fri, Jul 8, 2011 at 22:48, Alan Mackenzie wrote: > That's perfect! =C2=A0Thanks. I'm closing this one, then. Thanks, =C2=A0 =C2=A0 Juanma ------------=_1310167142-3463-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit >From acm@muc.de Wed Oct 22 02:57:47 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-7.0 required=4.0 tests=AWL,BAYES_00,GAPPY_SUBJECT, RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 22 Oct 2008 09:57:48 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9M9vicI002991 for ; Wed, 22 Oct 2008 02:57:46 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KsaTI-0003D5-35 for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KsaTH-0003Cp-1L for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:43 -0400 Received: from [199.232.76.173] (port=56870 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KsaTG-0003Cm-LH for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:42 -0400 Received: from colin.muc.de ([193.149.48.1]:1632 helo=mail.muc.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KsaTG-0006m4-EQ for bug-gnu-emacs@gnu.org; Wed, 22 Oct 2008 05:57:42 -0400 Received: (qmail 43226 invoked by uid 3782); 22 Oct 2008 09:57:40 -0000 Received: from acm.muc.de (pD9E5206A.dip.t-dialin.net [217.229.32.106]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Wed, 22 Oct 2008 11:57:39 +0200 Received: (qmail 3818 invoked by uid 1000); 22 Oct 2008 10:07:13 -0000 Date: Wed, 22 Oct 2008 10:07:13 +0000 To: bug-gnu-emacs@gnu.org Subject: Desktop holds second Emacs session hostage; C-x C-c doesn't work properly. Message-ID: <20081022100713.GC924@muc.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-detected-operating-system: by monty-python.gnu.org: FreeBSD 4.6-4.9 (i) With desktop enabled, start emacs. (ii) Start a second emacs session. Emacs2 detects Emacs1 and the danger of contention over .emacs.desktop. It prompts thusly: "Warning: desktop file appears to be in use by PID 3616. Using it may cause conflicts. Use it anyway? (y or n)" (iii) Type n. (iv) Attempt C-c C-x. Emacs2 decides, because desktop is "enabled", that it wants to save a desktop file, and prompts: "Directory for desktop file: ~/" At this point, C-g aborts the "end Emacs" command. One now has the unpleasant choice of killing Emacs2 from the (operating system) console or typing in some random directory to dump the empty .emacs.desktop to. This is a bug. Even worse, accepting the prompt's default directory, ~/, might overwrite the real .emacs.desktop. -- Alan Mackenzie (Nuremberg, Germany). ------------=_1310167142-3463-1--