From: Michael Albinus Date: Sun, 23 Feb 2014 14:51:29 +0000 (+0100) Subject: * net/tramp-sh.el (tramp-sh-handle-file-truename): Preserve trailing "/". X-Git-Tag: emacs-24.3.90~173^2^2~4 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=85c01f803fb003f33a30da2ebf157e69cd30c2cf;p=emacs.git * net/tramp-sh.el (tramp-sh-handle-file-truename): Preserve trailing "/". Fixes: debbugs:16851 --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 40f5d7defc1..de5dd56ddbb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-02-23 Michael Albinus + + * net/tramp-sh.el (tramp-sh-handle-file-truename): + Preserve trailing "/". (Bug#16851) + 2014-02-23 Dmitry Gutov * progmodes/ruby-mode.el (ruby-smie-rules): Don't indent specially @@ -130,7 +135,7 @@ (tramp-handle-insert-directory): New defun, taken from tramp-gvfs.el. * net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist) - : Use `tramp-handle-insert-directory. + : Use `tramp-handle-insert-directory'. (tramp-gvfs-handle-insert-directory): Remove function. * net/tramp-sh.el (tramp-sh-handle-insert-directory): diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 01abfe0e71f..efad151dac8 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -1042,7 +1042,8 @@ target of the symlink differ." (setq result (concat result "/")))))) (tramp-message v 4 "True name of `%s' is `%s'" localname result) - result))))) + (if (string-equal (file-name-nondirectory localname) "") + (file-name-as-directory result) result)))))) ;; Basic functions.