From: Richard M. Stallman Date: Sun, 28 Apr 2002 22:30:22 +0000 (+0000) Subject: (make-auto-save-file-name): Specify # as suffix in the non-file-visiting case. X-Git-Tag: ttn-vms-21-2-B4~15334 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3c4a7cf326091a804582f57c4a54aa2b465fea2f;p=emacs.git (make-auto-save-file-name): Specify # as suffix in the non-file-visiting case. --- diff --git a/lisp/files.el b/lisp/files.el index 353eb12375c..88f5b01ee8b 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -3372,17 +3372,17 @@ See also `auto-save-file-name-p'." (if (string-match (car (car list)) filename) (setq result (replace-match (cadr (car list)) t nil filename) - uniq (caddr (car list)))) + uniq (caddr (car list)))) (setq list (cdr list))) (if result - (if uniq - (setq filename (concat - (file-name-directory result) - (subst-char-in-string - directory-sep-char ?! - (replace-regexp-in-string "!" "!!" - filename)))) - (setq filename result))) + (if uniq + (setq filename (concat + (file-name-directory result) + (subst-char-in-string + directory-sep-char ?! + (replace-regexp-in-string "!" "!!" + filename)))) + (setq filename result))) (setq result (if (and (eq system-type 'ms-dos) (not (msdos-long-file-names))) @@ -3447,7 +3447,8 @@ See also `auto-save-file-name-p'." ;; file it creates, so we must fix the file name _before_ ;; make-temp-file is called. (convert-standard-filename fname) - fname)))))) + fname)) + nil "#")))) (defun auto-save-file-name-p (filename) "Return non-nil if FILENAME can be yielded by `make-auto-save-file-name'.