changeset 15892:6a4227841dec

(kill-region): inhibit-read-only overrides text props too.
author Richard M. Stallman <rms@gnu.org>
date Wed, 21 Aug 1996 16:20:39 +0000
parents dbc8c9c9d819
children 56d0b28891da
files lisp/simple.el
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/simple.el	Wed Aug 21 04:53:08 1996 +0000
+++ b/lisp/simple.el	Wed Aug 21 16:20:39 1996 +0000
@@ -1221,8 +1221,9 @@
    ;; If the buffer is read-only, we should beep, in case the person
    ;; just isn't aware of this.  However, there's no harm in putting
    ;; the region's text in the kill ring, anyway.
-   ((or (and buffer-read-only (not inhibit-read-only))
-	(text-property-not-all beg end 'read-only nil))
+   ((and (not inhibit-read-only)
+	 (or buffer-read-only
+	     (text-property-not-all beg end 'read-only nil)))
     (copy-region-as-kill beg end)
     ;; This should always barf, and give us the correct error.
     (if kill-read-only-ok