unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 13522@debbugs.gnu.org, vincent@vinc17.net
Subject: bug#13522: 24.2; save-buffer removes edited file under some conditions
Date: Tue, 15 Mar 2022 12:42:37 +0100	[thread overview]
Message-ID: <87ee33wifm.fsf@gnus.org> (raw)
In-Reply-To: <83fsnkk4so.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 14 Mar 2022 16:05:43 +0200")

Eli Zaretskii <eliz@gnu.org> writes:

>> And, yes, we make no guarantees, but the present situation doesn't seem
>> optimal.  The user may well hit `C-z' at the prompt and wonder where the
>> file disappeared to.
>
> That's in the "if it hurts, don't do that" department, IMO.  SIGINT is
> a fatal signal, and our response to fatal signals cannot be too
> fancy.  We just auto-save what we can and commit suicide.  Even that
> is disliked by some, who say we cannot safely do anything non-trivial
> from a fatal signal handler -- and they are absolutely right, we do
> stuff that invokes undefined behavior.

I agree that killing Emacs is unusual.  But suspending Emacs (with
`C-z') is something people do all the time, and in this case, if the
user is suspending Emacs on this prompt, they might be doing that to
examine the file before saving it, for instance.  And then they'll be
confused that it's apparently gone.

So I think we should fix this, perhaps the way Glenn suggested in his
patch, but it's obviously not high priority.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





  parent reply	other threads:[~2022-03-15 11:42 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-22  1:47 bug#13522: 24.2; save-buffer removes edited file under some conditions Vincent Lefevre
2013-01-24 20:28 ` Glenn Morris
2013-01-25  0:02   ` Vincent Lefevre
2013-01-25  0:48     ` Glenn Morris
2013-01-25  7:35       ` Eli Zaretskii
2013-01-25  8:07         ` Glenn Morris
2013-01-30  8:59           ` Glenn Morris
2013-01-30 19:34             ` Stefan Monnier
2013-01-31  6:36               ` Glenn Morris
2014-08-11  1:06                 ` Glenn Morris
2022-03-14 11:21 ` Lars Ingebrigtsen
2022-03-14 13:37   ` Eli Zaretskii
2022-03-14 13:43     ` Lars Ingebrigtsen
2022-03-14 14:05       ` Eli Zaretskii
2022-03-14 15:20         ` Vincent Lefevre
2022-03-14 17:02           ` Eli Zaretskii
2022-03-14 17:32             ` Vincent Lefevre
2022-03-15 11:42         ` Lars Ingebrigtsen [this message]
2022-03-15 14:23           ` Eli Zaretskii
2022-03-15 14:25             ` Lars Ingebrigtsen
2022-03-15 15:55               ` Vincent Lefevre
2022-04-30 16:47                 ` Lars Ingebrigtsen
2022-04-30 16:51                   ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ee33wifm.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=13522@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=vincent@vinc17.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).