GNU bug report logs - #18633
24.3; `customize-save-customized' should be handled as a transaction

Previous Next

Package: emacs;

Reported by: Matúš Goljer <matus.goljer <at> gmail.com>

Date: Sun, 5 Oct 2014 16:39:02 UTC

Severity: normal

Tags: fixed

Found in version 24.3

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 18633 in the body.
You can then email your comments to 18633 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#18633; Package emacs. (Sun, 05 Oct 2014 16:39:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Matúš Goljer <matus.goljer <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 05 Oct 2014 16:39:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Matúš Goljer <matus.goljer <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.3; `customize-save-customized' should be handled as a transaction
Date: Sun, 05 Oct 2014 16:18:00 +0200
If `customize-save-customized' is issued (through M-x or any other way,
such as C-x C-s in customize buffer), and during the run of the function
"exit" is called (e.g. using C-g), the routine writes garbage into the
`custom-set-variables' form in `custom-file'.

We should first construct the form in a temporary buffer and then write
it at once into the output file.  Another (simpler) solution is to use
`atomic-change-group' from subr.el

Had I not kept the file under git, I would've lost most of my settings.
It seems like a good idea to handle a critical operation like this
atomically.

Cheers.

-- 
Best regards,
  Matúš Goljer




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18633; Package emacs. (Fri, 04 Dec 2020 11:16:01 GMT) Full text and rfc822 format available.

Message #8 received at 18633 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Matúš Goljer <matus.goljer <at> gmail.com>
Cc: 18633 <at> debbugs.gnu.org
Subject: Re: bug#18633: 24.3; `customize-save-customized' should be handled
 as a transaction
Date: Fri, 04 Dec 2020 12:15:47 +0100
Matúš Goljer <matus.goljer <at> gmail.com> writes:

> We should first construct the form in a temporary buffer and then write
> it at once into the output file.  Another (simpler) solution is to use
> `atomic-change-group' from subr.el

(This bug report unfortunately got no response at the time.)

I've now done the latter in Emacs 28.

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




Added tag(s) fixed. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Fri, 04 Dec 2020 11:17:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 28.1, send any further explanations to 18633 <at> debbugs.gnu.org and Matúš Goljer <matus.goljer <at> gmail.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Fri, 04 Dec 2020 11:17:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 01 Jan 2021 12:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 226 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.