Subject: bug#17351: Trunk emacs splats .emacs.desktop at startup

From: Juri Linkov <[email-masked]>
Date: Fri, 27 Jun 2014 02:44:01 +0300

> I could equally well say that using save-buffer will cause the desktop
> to be included in the recentf list, which some people may dislike.
> (Cf http://debbugs.gnu.org/17155)

A solution in bug#17155 was to replace `save-buffer' with `write-region'
that is already currently used by desktop.el.  This means continuing
using low-level `write-region' would be less problematic than `save-buffer'
(and normal auto-saving of a file buffer that still requires `save-buffer'
at the end of the session).

> (This topic makes me wonder if desktop could have used the standard
> interlock mechanism, rather than inventing its own version of that too.)

This would be possible if the desktop file used `save-buffer' on
a normal file buffer instead of `write-region'.