From: Joe Wells <jbwells@blueyonder.co.uk>
To: Michael Heerdegen <michaelh@minet.uni-jena.de>
Cc: 457@emacsbugs.donarmstrong.com
Subject: bug#457: wdired and auto-revert-mode
Date: Mon, 11 Aug 2008 18:30:07 +0100 [thread overview]
Message-ID: <86k5enh334.fsf@blueyonder.co.uk> (raw)
In-Reply-To: <vs7fxpbtt2e.fsf@pax07e3.mipool.uni-jena.de> (Michael Heerdegen's message of "Mon\, 11 Aug 2008 18\:28\:09 +0200")
Michael Heerdegen <michaelh@minet.uni-jena.de> writes:
> I'll try to make clear what happened to the best of my recollection:
>
> (0) C-x d my-dir
>
> (1) I marked some files with % *, m, u etc.
>
> (2) I killed the formerly marked files in the dired buffer (k).
>
> (3) I pressed r (`wdired-change-to-wdired-mode') (resulting in making
> the buffer non-modified again).
Ahh! That's the bug: wdired-change-to-wdired-mode does
(set-buffer-modified-p nil), which incorrectly forgets about
modifications made by other commands.
In this case, (buffer-modified-p) is a poor proxy for “there exist
uncommitted changes that the user probably does not want to lose”.
The buffer-modified flag is mostly good enough for buffers visiting
ordinary files, but is hard to keep correct for fancy buffers like
Dired buffers. Of course, this wasn't so important before
auto-revert-mode existed.
--
Joe
> (4) Directly after that, M-x query-replace-regexp. While I was
> specifying the regexp, the buffer reverted, and I had to restart with (1).
next prev parent reply other threads:[~2008-08-11 17:30 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.15789.1217765249.18990.bug-gnu-emacs@gnu.org>
2008-08-04 11:18 ` bug#457: wdired and auto-revert-mode Joe Wells
2008-08-04 12:03 ` martin rudalics
2008-08-04 13:33 ` Joe Wells
2008-08-04 16:08 ` martin rudalics
2008-08-04 18:38 ` Joe Wells
2008-08-04 21:24 ` martin rudalics
[not found] ` <mailman.15844.1217875649.18990.bug-gnu-emacs@gnu.org>
2008-08-11 16:28 ` Michael Heerdegen
2008-08-11 17:30 ` Joe Wells [this message]
2008-08-13 16:22 ` Michael Heerdegen
2008-08-21 8:04 ` martin rudalics
2008-08-03 11:45 martin rudalics
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=86k5enh334.fsf@blueyonder.co.uk \
--to=jbwells@blueyonder.co.uk \
--cc=457@emacsbugs.donarmstrong.com \
--cc=michaelh@minet.uni-jena.de \
/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.