From: Oleh Krehel Date: Mon, 7 Mar 2016 20:37:58 +0000 (+0100) Subject: ivy.el (ivy-expand-file-if-directory): Fix "/ssh:" regression X-Git-Url: https://code.delx.au/gnu-emacs-elpa/commitdiff_plain/591c8fe22b3e0b89fd3bb83328d0b101508721ca ivy.el (ivy-expand-file-if-directory): Fix "/ssh:" regression --- diff --git a/ivy.el b/ivy.el index 5a1922794..fcac7d645 100644 --- a/ivy.el +++ b/ivy.el @@ -605,9 +605,11 @@ When ARG is t, exit with current text, ignoring the candidates." When this directory doesn't exist, return nil." (when (stringp file-name) (let ((full-name - (file-name-as-directory - (expand-file-name file-name ivy--directory)))) - (when (file-directory-p full-name) + ;; Ignore host name must not match method "ssh" + (ignore-errors + (file-name-as-directory + (expand-file-name file-name ivy--directory))))) + (when (and full-name (file-directory-p full-name)) full-name)))) (defcustom ivy-tab-space nil