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

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

bug#18633: 24.3; `customize-save-customized' should be handled as a tran


From: Matúš Goljer
Subject: bug#18633: 24.3; `customize-save-customized' should be handled as a transaction
Date: Sun, 05 Oct 2014 16:18:00 +0200
User-agent: Notmuch/0.18 (http://notmuchmail.org) Emacs/24.3.2 (x86_64-unknown-linux-gnu)

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





reply via email to

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