[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#18336: 24.4.50; When editing externally changed file, Emacs asks too
From: |
Eli Zaretskii |
Subject: |
bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions |
Date: |
Sun, 22 Mar 2020 16:35:02 +0200 |
> From: Noam Postavsky <npostavs@gmail.com>
> Cc: dak@gnu.org, stefan@marxist.se, 18336@debbugs.gnu.org
> Date: Sat, 21 Mar 2020 21:13:59 -0400
>
> >> Why exactly are we calling lock_file from write_region?
> >
> > Because write-region can be called from an unmodified buffer, I
> > suppose, and from a buffer whose buffer-file-name is not the same as
> > the file being written to.
>
> So maybe we could just check those conditions? Here's a patch,
> tentatively suggested for master.
Isn't it better to check whether the file is already locked? That
way, we don't need any (error-prone) heuristics for when it's okay to
ask the question and when it isn't.
> > Evidently, when we disabled backups in /tmp, we missed the fact that
> > lock_file called from write-region will be affected. When backups are
> > not disabled, this works correctly.
>
> To me, the fact that it works with backups enabled seems like an
> accident.
It might be an accident, but it's the reason why the default paradigm
works.
Thanks.
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, (continued)
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, David Kastrup, 2020/03/02
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/02
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Eli Zaretskii, 2020/03/02
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/05
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, David Kastrup, 2020/03/05
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/05
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Eli Zaretskii, 2020/03/05
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/21
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions,
Eli Zaretskii <=
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/22
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Eli Zaretskii, 2020/03/22
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/22
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Eli Zaretskii, 2020/03/22
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Noam Postavsky, 2020/03/22
- bug#18336: 24.4.50; When editing externally changed file, Emacs asks too many questions, Eli Zaretskii, 2020/03/05