* net/tramp.el (tramp-eshell-directory-change): Check remote-path
authorMichael Albinus <michael.albinus@gmx.de>
Wed, 9 Jan 2013 09:49:27 +0000 (10:49 +0100)
committerMichael Albinus <michael.albinus@gmx.de>
Wed, 9 Jan 2013 09:49:27 +0000 (10:49 +0100)
first in session cache: When `tramp-own-remote-path' is in
`tramp-remote-path', the remote path is only set in the session
cache.

lisp/ChangeLog
lisp/net/tramp.el

index e603217..35a8d11 100644 (file)
@@ -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)
index f8db03e..2c4aac0 100644 (file)
@@ -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"))))