From: Eli Zaretskii <eliz@gnu.org>
To: Vincent Lefevre <vincent@vinc17.net>
Cc: 18141@debbugs.gnu.org, yamaoka@jpl.org
Subject: bug#18141: 24.4.50; saving .gz file breaks file coding
Date: Wed, 06 Aug 2014 20:32:27 +0300 [thread overview]
Message-ID: <831tstplqs.fsf@gnu.org> (raw)
In-Reply-To: <20140806164316.GK4813@xvii.vinc17.org>
> Date: Wed, 6 Aug 2014 18:43:16 +0200
> From: Vincent Lefevre <vincent@vinc17.net>
> Cc: Glenn Morris <rgm@gnu.org>, 18141@debbugs.gnu.org, yamaoka@jpl.org
>
> On 2014-08-06 17:36:00 +0300, Eli Zaretskii wrote:
> > . Bug#13522, which these changes were trying to solve, happens when
> > Emacs is killed by an external signal during the time between
> > backing up the original file and writing the new one. (This time
> > can be quite large if write-region asks the user to choose a
> > suitable encoding for the new content.) That is a pretty rare
> > situation, and IMO it's perfectly OK for Emacs to leave just the
> > backup file if it was brutally killed during that time window.
>
> No, this is not rare
Maybe for you, because you are used to abort Emacs by a signal. I
never had such experiences in all the long years I'm using Emacs.
> (Emacs seems to be confused on files that have several encodings,
> such as mailboxes)
It does? I didn't see that since Emacs 23.1 at the least.
> and I sometimes hit Ctrl-C in the terminal (from which Emacs was
> started) to discard any change.
Then don't do that, if it hurts. C-g or M-~ or C-/ in Emacs will
discard changes (in different scenarios) without any adverse effects,
as will killing the buffer that visits the modified file. Why
brutally abort Emacs by a signal, when Emacs gives you better ways to
do that?
> And that's not OK to only leave the backup file,
> since it can be removed or overwritten pretty quickly, before
> I notice that the original file is gone.
Removed or overwritten by whom or what?
> But why isn't the backup done just before the file is actually
> written?
It _is_ done "just before", see basic-save-buffer-2.
next prev parent reply other threads:[~2014-08-06 17:32 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-29 6:59 bug#18141: 24.4.50; saving .gz file breaks file coding Katsumi Yamaoka
2014-07-30 0:10 ` Glenn Morris
2014-07-30 2:36 ` Katsumi Yamaoka
2014-07-30 13:15 ` Katsumi Yamaoka
2014-08-05 8:34 ` Glenn Morris
2014-08-06 14:36 ` Eli Zaretskii
2014-08-06 16:43 ` Vincent Lefevre
2014-08-06 17:32 ` Eli Zaretskii [this message]
2014-08-06 19:08 ` Vincent Lefevre
2014-08-06 19:45 ` Eli Zaretskii
2014-08-07 0:31 ` Vincent Lefevre
2014-08-07 12:20 ` Stefan Monnier
2014-08-07 14:23 ` Vincent Lefevre
2014-08-11 1:06 ` Glenn Morris
2014-08-06 17:48 ` Stefan Monnier
2014-08-06 18:10 ` Eli Zaretskii
2014-08-07 0:45 ` Stefan Monnier
2014-08-07 15:14 ` Eli Zaretskii
2014-08-07 19:08 ` Stefan Monnier
2014-08-07 19:37 ` Eli Zaretskii
2014-08-07 20:43 ` Stefan Monnier
2014-08-08 5:51 ` Eli Zaretskii
2014-08-06 23:45 ` Glenn Morris
2014-08-07 0:03 ` Glenn Morris
2014-08-07 12:14 ` Stefan Monnier
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=831tstplqs.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=18141@debbugs.gnu.org \
--cc=vincent@vinc17.net \
--cc=yamaoka@jpl.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.