Mercurial > emacs
diff lisp/minibuffer.el @ 105589:e84a6a47bcb9
(completion--file-name-table): Return nil if there's
no file completion, even if substitute-in-file-name changed
the string (bug#4708).
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Wed, 14 Oct 2009 03:05:06 +0000 |
parents | 13f171fbff05 |
children | 117859152fa5 |
line wrap: on
line diff
--- a/lisp/minibuffer.el Tue Oct 13 22:35:44 2009 +0000 +++ b/lisp/minibuffer.el Wed Oct 14 03:05:06 2009 +0000 @@ -1078,16 +1078,18 @@ ((null action) (let ((comp (file-name-completion name realdir read-file-name-predicate))) - (if (stringp comp) - ;; Requote the $s before returning the completion. - (minibuffer--double-dollars (concat specdir comp)) + (cond + ((stringp comp) + ;; Requote the $s before returning the completion. + (minibuffer--double-dollars (concat specdir comp))) + (comp ;; Requote the $s before checking for changes. (setq str (minibuffer--double-dollars str)) (if (string-equal string str) comp ;; If there's no real completion, but substitute-in-file-name ;; changed the string, then return the new string. - str)))) + str))))) ((eq action t) (let ((all (file-name-all-completions name realdir)))