changeset 44351:974edbcc8ecd

(hack-one-local-variable): Clear text props from string value.
author Richard M. Stallman <rms@gnu.org>
date Tue, 02 Apr 2002 23:14:26 +0000
parents 89727a7321d0
children d38932df86fc
files lisp/files.el
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/files.el	Tue Apr 02 22:32:15 2002 +0000
+++ b/lisp/files.el	Tue Apr 02 23:14:26 2002 +0000
@@ -1994,6 +1994,11 @@
 	   (message "Ignoring `eval:' in the local variables list")))
 	;; Ordinary variable, really set it.
 	(t (make-local-variable var)
+	   ;; Make sure the string has no text properties.
+	   ;; Some text properties can get evaluated in various ways,
+	   ;; so it is risky to put them on with a local variable list.
+	   (if (stringp val)
+	       (set-text-properties 0 (length val) nil val))
 	   (set var val))))