diff options
author | Juanma Barranquero <lekktu@gmail.com> | 2009-10-02 03:48:36 +0000 |
---|---|---|
committer | Juanma Barranquero <lekktu@gmail.com> | 2009-10-02 03:48:36 +0000 |
commit | 32226619c5e563c384372b566000e5d37d783a61 (patch) | |
tree | 216af4221d2ba868b45162679ce3a0462985c422 /lisp/files.el | |
parent | 12a3c28c787e23801f40ea557a5c00b538968a52 (diff) | |
download | emacs-32226619c5e563c384372b566000e5d37d783a61.tar.gz |
Use `called-interactively-p' instead of `interactive-p'.
Diffstat (limited to 'lisp/files.el')
-rw-r--r-- | lisp/files.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/files.el b/lisp/files.el index 61de4cb1704..ac058efde08 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -1382,7 +1382,8 @@ expand wildcards (if any) and visit multiple files." Like \\[find-file], but only allow a file that exists, and do not allow file names with wildcards." (interactive (nbutlast (find-file-read-args "Find existing file: " t))) - (if (and (not (interactive-p)) (not (file-exists-p filename))) + (if (and (not (called-interactively-p 'interactive)) + (not (file-exists-p filename))) (error "%s does not exist" filename) (find-file filename) (current-buffer))) @@ -5067,7 +5068,7 @@ With prefix argument ARG, turn auto-saving on if positive, else off." ;; turn it back on. (and (< buffer-saved-size 0) (setq buffer-saved-size 0)) - (if (interactive-p) + (if (called-interactively-p 'interactive) (message "Auto-save %s (in this buffer)" (if buffer-auto-save-file-name "on" "off"))) buffer-auto-save-file-name) |