summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Albinus <michael.albinus@gmx.de>2013-01-09 10:49:27 +0100
committerMichael Albinus <michael.albinus@gmx.de>2013-01-09 10:49:27 +0100
commitccd04887a3f15ce0e52af801d8a70c91d695f78c (patch)
treec604ac3dbb3b61f4849b7692d4489db2530619e9
parentfb9f7146677ca0d6f03ca88dd8cd39bc3733682d (diff)
downloademacs-ccd04887a3f15ce0e52af801d8a70c91d695f78c.tar.gz
* net/tramp.el (tramp-eshell-directory-change): Check remote-path
first in session cache: When `tramp-own-remote-path' is in `tramp-remote-path', the remote path is only set in the session cache.
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/net/tramp.el7
2 files changed, 13 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index e60321744bb..35a8d1171db 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
+2013-01-09 Jürgen Hötzel <juergen@archlinux.org>
+
+ * net/tramp.el (tramp-eshell-directory-change): Check remote-path
+ first in session cache: When `tramp-own-remote-path' is in
+ `tramp-remote-path', the remote path is only set in the session
+ cache.
+
2013-01-09 Glenn Morris <rgm@gnu.org>
* emacs-lisp/trace.el (trace-function-foreground)
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el
index f8db03ee4d7..2c4aac0ac8a 100644
--- a/lisp/net/tramp.el
+++ b/lisp/net/tramp.el
@@ -3901,7 +3901,12 @@ Only works for Bourne-like shells."
(with-parsed-tramp-file-name default-directory nil
(mapconcat
'identity
- (tramp-get-connection-property v "remote-path" nil)
+ (or
+ ;; When `tramp-own-remote-path' is in `tramp-remote-path',
+ ;; the remote path is only set in the session cache.
+ (tramp-get-connection-property
+ (tramp-get-connection-process v) "remote-path" nil)
+ (tramp-get-connection-property v "remote-path" nil))
":"))
(getenv "PATH"))))