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

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

Re: savehist-autosave should be wrapped in a condition-case


From: Hrvoje Niksic
Subject: Re: savehist-autosave should be wrapped in a condition-case
Date: Thu, 01 Dec 2005 20:55:04 +0100
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux)

"Drew Adams" <address@hidden> writes:

> Because it's always possible for a history list to end up containing
> malformed entries,

Really?  How can that happen?

> in my local copy of savehist.el I have added this condition-case:
>
> (defun savehist-autosave ()
>   "Save the minibuffer history if it has been modified since the last
> save."
>   (condition-case nil
>       (savehist-save t)
>     (error nil)))

The problem with this is that it effectively disables saving the
history until you reenter Emacs.  savehist-save could check for
"printability" of each history list, but that check does not come
without a cost and I wanted to avoid it if I could.




reply via email to

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