bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#54401: 28.0.91; Buffer visited file replaced with lockfile location


From: Lars Ingebrigtsen
Subject: bug#54401: 28.0.91; Buffer visited file replaced with lockfile location
Date: Thu, 17 Mar 2022 12:20:37 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Kenny Ballou <kb@devnulllabs.io> writes:

> This may be a "won't-fix", but I seemed to have stumbled onto an issue where
> the visited file of the current buffer is replaced by the lock file location 
> on
> file renames when using `auto-save-visited-file-name`.
>
> The minimal configuration (`emacs -Q`) to trigger the bug is the following:
>
> ```
> (setq auto-save-visited-file-name t)
> (setq auto-save-default t)
> (setq auto-save-timeout 20)
> (setq auto-save-interval 20)

You only need the first, apparently.  And there's more bugginess going
on than described.

In Emacs 29:

emacs -Q
M-: (setq auto-save-visited-file-name t) RET
C-x C-f /tmp/foo1 RET
<type something> `C-x C-s'

Observe that the /tmp/foo1 file exists.

`C-x C-w /tmp/foo2 RET'

/tmp/foo1 no longer exists!  But /tmp/foo2 does.

<type something>
`M-x do-auto-save RET'

/tmp/#foo2# now exists!  And `buffer-file-name' in the "foo2" buffer is
now "/tmp/#foo2#'

So this is kinda totally broken.  Now, `auto-save-visited-file-name' was
made obsolete in Emacs 26.1, but perhaps these things should be fixed
anyway.

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





reply via email to

[Prev in Thread] Current Thread [Next in Thread]