diff options
author | Chong Yidong <cyd@stupidchicken.com> | 2006-09-26 18:05:41 +0000 |
---|---|---|
committer | Chong Yidong <cyd@stupidchicken.com> | 2006-09-26 18:05:41 +0000 |
commit | 90e93246f3c9bcb309d706728c3215ada77638ec (patch) | |
tree | 802d42ed7a016a49cc672684f48d180b4840cb45 /lisp/gnus/gnus-demon.el | |
parent | 44ea768c8c9ebe99e7e41c2b6f539173e6a4a384 (diff) | |
download | emacs-90e93246f3c9bcb309d706728c3215ada77638ec.tar.gz |
* gnus-demon.el (gnus-demon): Use with-local-quit to avoid hangs.
Diffstat (limited to 'lisp/gnus/gnus-demon.el')
-rw-r--r-- | lisp/gnus/gnus-demon.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/gnus/gnus-demon.el b/lisp/gnus/gnus-demon.el index 8df3a3b0e70..bf35f1ddee7 100644 --- a/lisp/gnus/gnus-demon.el +++ b/lisp/gnus/gnus-demon.el @@ -218,7 +218,7 @@ time Emacs has been idle for IDLE `gnus-demon-timestep's." (< idle gnus-demon-idle-time)) ; Idle timed out. (t (< 0 gnus-demon-idle-time)))) ; Or just need to be idle. ;; So we call the handler. - (progn + (with-local-quit (ignore-errors (funcall (car handler))) ;; And reset the timer. (setcar (nthcdr 1 handler) @@ -232,14 +232,15 @@ time Emacs has been idle for IDLE `gnus-demon-timestep's." (gnus-demon-is-idle-p)) ;; We want to call this handler each and every time that ;; Emacs is idle. - (ignore-errors (funcall (car handler)))) + (with-local-quit + (ignore-errors (funcall (car handler))))) (t ;; We want to call this handler only if Emacs has been idle ;; for a specified number of timesteps. (and (not (memq (car handler) gnus-demon-idle-has-been-called)) (< idle gnus-demon-idle-time) (gnus-demon-is-idle-p) - (progn + (with-local-quit (ignore-errors (funcall (car handler))) ;; Make sure the handler won't be called once more in ;; this idle-cycle. |