]> git.eshelyaron.com Git - emacs.git/commitdiff
(find-file-noselect): Don't consider a buffer as
authorEli Zaretskii <eliz@gnu.org>
Sun, 13 Jan 2002 08:50:04 +0000 (08:50 +0000)
committerEli Zaretskii <eliz@gnu.org>
Sun, 13 Jan 2002 08:50:04 +0000 (08:50 +0000)
visiting a file literally if it is in hexl-mode.

lisp/ChangeLog
lisp/files.el

index 1691198ea928c0e839f052a1c0ce8f3e8851a03a..9071ef02e4c7664afe79f111580559c74df38963 100644 (file)
@@ -1,3 +1,8 @@
+2002-01-13  Eli Zaretskii  <eliz@is.elta.co.il>
+
+       * files.el (find-file-noselect): Don't consider a buffer as
+       visiting a file literally if it is in hexl-mode.
+
 2001-12-29  Richard M. Stallman  <rms@gnu.org>
 
        * net/ange-ftp.el (ange-ftp-allow-child-lookup): Always return nil.
index b7201bdd459153bd2ee5711f514c3204bf53089a..12ad644cf32a7ead22d1ee9999cfe490bea9496c 100644 (file)
@@ -1071,8 +1071,12 @@ that are visiting the various files."
                         (with-current-buffer buf
                           (revert-buffer t t)))))
              (with-current-buffer buf
-               (when (not (eq (not (null rawfile))
-                              (not (null find-file-literally))))
+               (when (and (not (eq (not (null rawfile))
+                                   (not (null find-file-literally))))
+                          ;; It is confusing to ask whether to visit
+                          ;; non-literally if they have the file in
+                          ;; hexl-mode.
+                          (not (eq major-mode 'hexl-mode)))
                  (if (buffer-modified-p)
                      (if (y-or-n-p (if rawfile
                                        "Save file and revisit literally? "