aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman <[email protected]>1993-01-02 21:21:14 +0000
committerRichard M. Stallman <[email protected]>1993-01-02 21:21:14 +0000
commitfdcba502fabb3a06669fa43bf20a84c8fb7d185e (patch)
tree6007fcf579da9e3714d439810166eea263babe95
parent76a66e5e9fcabb8735019500e273e6205d3f3f2c (diff)
(compilation-sentinel): Change buffer-read-only with let.
-rw-r--r--lisp/progmodes/compile.el39
1 files changed, 19 insertions, 20 deletions
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el
index 45e4905b87..3c47657c91 100644
--- a/lisp/progmodes/compile.el
+++ b/lisp/progmodes/compile.el
@@ -367,26 +367,25 @@ Runs `compilation-mode-hook' with `run-hooks' (which see)."
;; Write something in the compilation buffer
;; and hack its mode line.
(set-buffer buffer)
- (setq buffer-read-only nil)
- (setq omax (point-max)
- opoint (point))
- (goto-char omax)
- ;; Record where we put the message, so we can ignore it
- ;; later on.
- (insert ?\n mode-name " " msg)
- (forward-char -1)
- (insert " at " (substring (current-time-string) 0 19))
- (forward-char 1)
- (setq mode-line-process
- (concat ": "
- (symbol-name (process-status proc))))
- ;; Since the buffer and mode line will show that the
- ;; process is dead, we can delete it now. Otherwise it
- ;; will stay around until M-x list-processes.
- (delete-process proc)
- ;; Force mode line redisplay soon.
- (set-buffer-modified-p (buffer-modified-p))
- (setq buffer-read-only t) ;I think is this wrong --roland
+ (let ((buffer-read-only nil))
+ (setq omax (point-max)
+ opoint (point))
+ (goto-char omax)
+ ;; Record where we put the message, so we can ignore it
+ ;; later on.
+ (insert ?\n mode-name " " msg)
+ (forward-char -1)
+ (insert " at " (substring (current-time-string) 0 19))
+ (forward-char 1)
+ (setq mode-line-process
+ (concat ": "
+ (symbol-name (process-status proc))))
+ ;; Since the buffer and mode line will show that the
+ ;; process is dead, we can delete it now. Otherwise it
+ ;; will stay around until M-x list-processes.
+ (delete-process proc)
+ ;; Force mode line redisplay soon.
+ (set-buffer-modified-p (buffer-modified-p)))
(if (and opoint (< opoint omax))
(goto-char opoint))
(if compilation-finish-function