diff options
author | Kim F. Storm <[email protected]> | 2002-07-07 23:15:04 +0000 |
---|---|---|
committer | Kim F. Storm <[email protected]> | 2002-07-07 23:15:04 +0000 |
commit | 879365c68f72f63a0ad631d11bff2cca4a3aade1 (patch) | |
tree | 8c1fb9d2309eace23a072f50638f05b38182463a /lisp/files.el | |
parent | 9304c6200589ae7bf0717783a6f62219e60888dc (diff) |
(after-find-file): Don't check for read-only status
of files just created (and not yet saved on disk).
Diffstat (limited to 'lisp/files.el')
-rw-r--r-- | lisp/files.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/files.el b/lisp/files.el index a93759298c..27ecf1901d 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -1424,7 +1424,8 @@ unless NOMODES is non-nil." (setq buffer-read-only t)) ;; When a file is marked read-only, ;; make the buffer read-only even if root is looking at it. - (when (zerop (logand (file-modes (buffer-file-name)) #o222)) + (when (and (file-modes (buffer-file-name)) + (zerop (logand (file-modes (buffer-file-name)) #o222))) (setq buffer-read-only t)) (unless nomodes (when (and view-read-only view-mode) |