Avoid errors in Auto Revert mode
* lisp/autorevert.el (auto-revert-buffers): Cancel auto-revert-timer only if it is non-nil. This avoids errors on first invocation of Auto-Revert mode.
This commit is contained in:
parent
a3b193516f
commit
82d4b9872f
1 changed files with 2 additions and 1 deletions
|
@ -813,7 +813,8 @@ the timer when no buffers need to be checked."
|
|||
;; Check if we should cancel the timer.
|
||||
(when (and (not global-auto-revert-mode)
|
||||
(null auto-revert-buffer-list))
|
||||
(cancel-timer auto-revert-timer)
|
||||
(if (timerp auto-revert-timer)
|
||||
(cancel-timer auto-revert-timer))
|
||||
(setq auto-revert-timer nil)))))
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue