# HG changeset patch # User Chong Yidong # Date 1257127596 0 # Node ID 06f1348e32791d756053e60f06bc0f6346bc1140 # Parent dd97d1526b9fb4ac5eb3bbcdb791fd66bd5efbef * minibuffer.el (read-file-name): Don't use file dialogs for remote directories (Bug#99). diff -r dd97d1526b9f -r 06f1348e3279 lisp/ChangeLog --- a/lisp/ChangeLog Sun Nov 01 17:44:04 2009 +0000 +++ b/lisp/ChangeLog Mon Nov 02 02:06:36 2009 +0000 @@ -1,3 +1,8 @@ +2009-11-02 Chong Yidong + + * minibuffer.el (read-file-name): Don't use file dialogs for + remote directories (Bug#99). + 2009-11-01 Chong Yidong * progmodes/sh-script.el (sh-font-lock-paren): Fix last change. diff -r dd97d1526b9f -r 06f1348e3279 lisp/minibuffer.el --- a/lisp/minibuffer.el Sun Nov 01 17:44:04 2009 +0000 +++ b/lisp/minibuffer.el Mon Nov 02 02:06:36 2009 +0000 @@ -1292,9 +1292,10 @@ If this command was invoked with the mouse, use a graphical file dialog if `use-dialog-box' is non-nil, and the window system or X -toolkit in use provides a file dialog box. For graphical file -dialogs, any the special values of MUSTMATCH; `confirm' and -`confirm-after-completion' are treated as equivalent to nil. +toolkit in use provides a file dialog box, and DIR is not a +remote file. For graphical file dialogs, any the special values +of MUSTMATCH; `confirm' and `confirm-after-completion' are +treated as equivalent to nil. See also `read-file-name-completion-ignore-case' and `read-file-name-function'." @@ -1325,7 +1326,10 @@ (add-to-history nil)) (let* ((val - (if (not (next-read-file-uses-dialog-p)) + (if (or (not (next-read-file-uses-dialog-p)) + ;; Graphical file dialogs can't handle remote + ;; files (Bug#99). + (file-remote-p dir)) ;; We used to pass `dir' to `read-file-name-internal' by ;; abusing the `predicate' argument. It's better to ;; just use `default-directory', but in order to avoid