diff options
author | Michael Albinus <michael.albinus@gmx.de> | 2018-07-20 10:56:41 +0200 |
---|---|---|
committer | Michael Albinus <michael.albinus@gmx.de> | 2018-07-20 10:56:41 +0200 |
commit | 61de292c72382403633f753c3d632a560ccfee98 (patch) | |
tree | 54a8d8efab8abbf387ed722abadf5cab5faea8d0 /lisp/net/tramp-sh.el | |
parent | 3e722980df9d4a705394c843a2a5e051e9c682b6 (diff) | |
download | emacs-61de292c72382403633f753c3d632a560ccfee98.tar.gz emacs-61de292c72382403633f753c3d632a560ccfee98.tar.bz2 emacs-61de292c72382403633f753c3d632a560ccfee98.zip |
Fix (Bug#32218). Do not merge with master
* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.3.4.26.2".
(customize-package-emacs-version-alist): Add Tramp version
integrated in Emacs 26.2.
* lisp/net/tramp.el (tramp-handle-file-truename):
* lisp/net/tramp-adb.el (tramp-adb-handle-file-truename):
* lisp/net/tramp-sh.el (tramp-sh-handle-file-truename): Fix problem
with trailing slash. (Bug#32218)
* test/lisp/net/tramp-tests.el (tramp-test21-file-links):
Remove `tramp--test-emacs27-p' check.
Diffstat (limited to 'lisp/net/tramp-sh.el')
-rw-r--r-- | lisp/net/tramp-sh.el | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 212be4f36a0..3f83697c6bf 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -1118,8 +1118,10 @@ component is used as the target of the symlink." (defun tramp-sh-handle-file-truename (filename) "Like `file-truename' for Tramp files." - (format - "%s%s" + ;; Preserve trailing "/". + (funcall + (if (string-equal (file-name-nondirectory filename) "") + 'file-name-as-directory 'identity) (with-parsed-tramp-file-name (expand-file-name filename) nil (tramp-make-tramp-file-name method user domain host port @@ -1223,10 +1225,7 @@ component is used as the target of the symlink." (let (file-name-handler-alist) (setq result (tramp-compat-file-name-quote result)))) (tramp-message v 4 "True name of `%s' is `%s'" localname result) - result)))) - - ;; Preserve trailing "/". - (if (string-equal (file-name-nondirectory filename) "") "/" ""))) + result)))))) ;; Basic functions. |