]> code.delx.au - gnu-emacs/commitdiff
(auto-revert-handler): Bind `buffer-read-only' locally around the call
authorLuc Teirlinck <teirllm@auburn.edu>
Fri, 3 Sep 2004 22:28:10 +0000 (22:28 +0000)
committerLuc Teirlinck <teirllm@auburn.edu>
Fri, 3 Sep 2004 22:28:10 +0000 (22:28 +0000)
to `revert-buffer'.

lisp/ChangeLog
lisp/autorevert.el

index 130ee51e80f9c4d22ed79cdd2454e61099406ef5..96fa1656f0a6c1f8a53aaef846f9b2c034a4eae6 100644 (file)
@@ -1,3 +1,8 @@
+2004-09-03  Luc Teirlinck  <teirllm@auburn.edu>
+
+       * autorevert.el (auto-revert-handler): Bind `buffer-read-only'
+       locally around the call to `revert-buffer'.
+
 2004-09-03  Juri Linkov  <juri@jurta.org>
 
        * isearch.el (isearch-toggle-regexp): Set `isearch-success' and
index 796ebaa27c82d32cbf283a66a7ee98ea3c7c4ac9..ecf768c573201e1e7456e9596aaa7b0b890706f5 100644 (file)
@@ -421,7 +421,8 @@ This is an internal function used by Auto-Revert Mode."
           'no-mini t))
        (if auto-revert-tail-mode
            (auto-revert-tail-handler)
-         (revert-buffer 'ignore-auto 'dont-ask 'preserve-modes))
+         (let ((buffer-read-only buffer-read-only))
+           (revert-buffer 'ignore-auto 'dont-ask 'preserve-modes)))
        (when buffer-file-name
          (when eob (goto-char (point-max)))
          (dolist (window eoblist)