diff options
author | Leo Liu <sdl.web@gmail.com> | 2013-03-24 14:42:25 +0800 |
---|---|---|
committer | Leo Liu <sdl.web@gmail.com> | 2013-03-24 14:42:25 +0800 |
commit | 7b0e2f853fcd88c58715fd159923d50dfdeb9cba (patch) | |
tree | 43c47e8af99b49d98f2fd1443a8641c37a225908 /lisp/nxml | |
parent | 2bf7d27acd741bf870d6ca0c74dbed7b7260b5ad (diff) | |
download | emacs-7b0e2f853fcd88c58715fd159923d50dfdeb9cba.tar.gz |
* lisp/files.el (kill-buffer-hook): Doc fix.
* lisp/emacs-lisp/edebug.el (edebug-mode): Make sure edebug-kill-buffer
is the last entry in kill-buffer-hook.
* lisp/nxml/rng-valid.el (rng-validate-while-idle)
(rng-validate-quick-while-idle): Guard against deleted buffer.
Fixes: debbugs:13999
Diffstat (limited to 'lisp/nxml')
-rw-r--r-- | lisp/nxml/rng-valid.el | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/lisp/nxml/rng-valid.el b/lisp/nxml/rng-valid.el index de18c581421..e1140980813 100644 --- a/lisp/nxml/rng-valid.el +++ b/lisp/nxml/rng-valid.el @@ -433,24 +433,26 @@ The schema is set like `rng-auto-set-schema'." ;; validation process down. (defun rng-validate-while-idle (buffer) - (with-current-buffer buffer - (if rng-validate-mode - (if (let ((rng-validate-display-point (point)) - (rng-validate-display-modified-p (buffer-modified-p))) - (rng-do-some-validation 'rng-validate-while-idle-continue-p)) - (force-mode-line-update) - (rng-validate-done)) - ;; must have done kill-all-local-variables - (rng-kill-timers)))) + (when (buffer-live-p buffer) ; bug#13999 + (with-current-buffer buffer + (if rng-validate-mode + (if (let ((rng-validate-display-point (point)) + (rng-validate-display-modified-p (buffer-modified-p))) + (rng-do-some-validation 'rng-validate-while-idle-continue-p)) + (force-mode-line-update) + (rng-validate-done)) + ;; must have done kill-all-local-variables + (rng-kill-timers))))) (defun rng-validate-quick-while-idle (buffer) - (with-current-buffer buffer - (if rng-validate-mode - (if (rng-do-some-validation) - (force-mode-line-update) - (rng-validate-done)) - ;; must have done kill-all-local-variables - (rng-kill-timers)))) + (when (buffer-live-p buffer) ; bug#13999 + (with-current-buffer buffer + (if rng-validate-mode + (if (rng-do-some-validation) + (force-mode-line-update) + (rng-validate-done)) + ;; must have done kill-all-local-variables + (rng-kill-timers))))) (defun rng-validate-done () (when (or (not (current-message)) |