changeset 18894:5456507de2dd

(find-file-literally): Temporarily remove tar-mode and archive-mode from auto-mode-alist.
author Richard M. Stallman <rms@gnu.org>
date Mon, 21 Jul 1997 06:16:33 +0000
parents de4c911119b4
children 13688b320903
files lisp/files.el
diffstat 1 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/files.el	Mon Jul 21 06:00:23 1997 +0000
+++ b/lisp/files.el	Mon Jul 21 06:16:33 1997 +0000
@@ -954,9 +954,19 @@
   (interactive "FFind file literally: ")
   (let ((coding-system-for-read 'no-conversion)
 	(coding-system-for-write 'no-conversion)
+	(auto-mode-alist (copy-sequence auto-mode-alist))
 	(jka-compr-compression-info-list nil)
 	(format-alist nil)
-	(after-insert-file-functions nil))
+	(after-insert-file-functions nil)
+	tail)
+    ;; Turn off use of tar-mode and archive-mode
+    ;; for this one file.  (We copied auto-mode-alist above
+    ;; so as not to alter it permanently.)
+    (setq tail auto-mode-alist)
+    (while tail
+      (if (memq (cdr (car tail)) '(tar-mode archive-mode))
+	  (setq auto-mode-alist (delq (car tail) auto-mode-alist)))
+      (setq tail (cdr tail)))
     (prog1
 	(find-file filename)
       (setq enable-multibyte-characters nil))))