summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1992-10-04 03:46:01 +0000
committerRichard M. Stallman <rms@gnu.org>1992-10-04 03:46:01 +0000
commit58ff020d725b2ded734ea4e12edf3edbb90b5299 (patch)
tree98339a2441e13ceef9cc0d8b42121e1309ccc1c0 /lisp
parentaf36339a347da5641eb79f33507d43b8543b4169 (diff)
downloademacs-58ff020d725b2ded734ea4e12edf3edbb90b5299.tar.gz
(insert-buffer): Before reading arg, barf if read-only.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/simple.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 243b1eeb211..b3e756c780e 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -1057,7 +1057,8 @@ With argument, rotate that many kills forward (or backward, if negative)."
"Insert after point the contents of BUFFER.
Puts mark after the inserted text.
BUFFER may be a buffer or a buffer name."
- (interactive (list (read-buffer "Insert buffer: " (other-buffer) t)))
+ (interactive (list (progn (barf-if-buffer-read-only)
+ (read-buffer "Insert buffer: " (other-buffer) t))))
(or (bufferp buffer)
(setq buffer (get-buffer buffer)))
(let (start end newmark)