aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Albinus2008-04-28 19:32:41 +0000
committerMichael Albinus2008-04-28 19:32:41 +0000
commit76f31f76830a8ffe78cf86187ba2bf9cbae0f61c (patch)
tree5d0fc8c41152c0e9c5059fe9de5e0299a282a161
parent05a27ce5ccda276939037119ce2616053eaf5d7a (diff)
downloademacs-76f31f76830a8ffe78cf86187ba2bf9cbae0f61c.tar.gz
emacs-76f31f76830a8ffe78cf86187ba2bf9cbae0f61c.zip
* net/tramp.el (tramp-replace-environment-variables): Remove it.
There is a more simple solution. (tramp-file-name-handler): Apply `substitute-in-file-name' w/o Tramp file name handlers.
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/net/tramp.el15
2 files changed, 10 insertions, 12 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 80aeddee9ce..673c28f021b 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
12008-04-28 Michael Albinus <michael.albinus@gmx.de>
2
3 * net/tramp.el (tramp-replace-environment-variables): Remove it.
4 There is a more simple solution.
5 (tramp-file-name-handler): Apply `substitute-in-file-name' w/o
6 Tramp file name handlers.
7
12008-04-28 Nick Roberts <nickrob@snap.net.nz> 82008-04-28 Nick Roberts <nickrob@snap.net.nz>
2 9
3 * progmodes/gdb-ui.el (gdb-info-breakpoints-custom): Make breakpoint 10 * progmodes/gdb-ui.el (gdb-info-breakpoints-custom): Make breakpoint
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el
index 98eb93aa208..5b2c9525b25 100644
--- a/lisp/net/tramp.el
+++ b/lisp/net/tramp.el
@@ -4375,16 +4375,6 @@ ARGS are the arguments OPERATION has been called with."
4375 (setq res (cdr elt)))) 4375 (setq res (cdr elt))))
4376 res))) 4376 res)))
4377 4377
4378(defun tramp-replace-environment-variables (filename)
4379 "Replace environment variables in FILENAME.
4380Return the string with the replaced variables."
4381 (when (string-match "$\\w+" filename)
4382 (setq filename
4383 (replace-match
4384 (substitute-in-file-name (match-string 0 filename))
4385 t nil filename)))
4386 filename)
4387
4388;; Main function. 4378;; Main function.
4389;;;###autoload 4379;;;###autoload
4390(defun tramp-file-name-handler (operation &rest args) 4380(defun tramp-file-name-handler (operation &rest args)
@@ -4394,8 +4384,9 @@ Falls back to normal file name handler if no tramp file name handler exists."
4394;; (edebug-trace "%s" (with-output-to-string (backtrace))) 4384;; (edebug-trace "%s" (with-output-to-string (backtrace)))
4395 (save-match-data 4385 (save-match-data
4396 (let* ((filename 4386 (let* ((filename
4397 (tramp-replace-environment-variables 4387 (tramp-run-real-handler
4398 (apply 'tramp-file-name-for-operation operation args))) 4388 'substitute-in-file-name
4389 (list (apply 'tramp-file-name-for-operation operation args))))
4399 (completion (tramp-completion-mode-p filename)) 4390 (completion (tramp-completion-mode-p filename))
4400 (foreign (tramp-find-foreign-file-name-handler filename))) 4391 (foreign (tramp-find-foreign-file-name-handler filename)))
4401 (with-parsed-tramp-file-name filename nil 4392 (with-parsed-tramp-file-name filename nil