aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/replace.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/replace.el')
-rw-r--r--lisp/replace.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/replace.el b/lisp/replace.el
index a66c9c0dfc2..7366d7fa49f 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -332,7 +332,9 @@ on the contents of the region. Otherwise, operate from point to the
332end of the buffer." 332end of the buffer."
333 333
334 (interactive 334 (interactive
335 (keep-lines-read-args "Keep lines (containing match for regexp): ")) 335 (progn
336 (barf-if-buffer-read-only)
337 (keep-lines-read-args "Keep lines (containing match for regexp): ")))
336 (if rstart 338 (if rstart
337 (progn 339 (progn
338 (goto-char (min rstart rend)) 340 (goto-char (min rstart rend))
@@ -381,7 +383,9 @@ on the contents of the region. Otherwise, operate from point to the
381end of the buffer." 383end of the buffer."
382 384
383 (interactive 385 (interactive
384 (keep-lines-read-args "Flush lines (containing match for regexp): ")) 386 (progn
387 (barf-if-buffer-read-only)
388 (keep-lines-read-args "Flush lines (containing match for regexp): ")))
385 (if rstart 389 (if rstart
386 (progn 390 (progn
387 (goto-char (min rstart rend)) 391 (goto-char (min rstart rend))