diff options
| author | Michael Albinus | 2008-06-08 10:49:19 +0000 |
|---|---|---|
| committer | Michael Albinus | 2008-06-08 10:49:19 +0000 |
| commit | 48846dc595ab1fcd3713457b0c6c379a54fdf2d1 (patch) | |
| tree | ff4919dae1f7701fe587b3ccc240842322eb24d6 | |
| parent | b8206d82a5b56d3e466e59e378170fce3d560c64 (diff) | |
| download | emacs-48846dc595ab1fcd3713457b0c6c379a54fdf2d1.tar.gz emacs-48846dc595ab1fcd3713457b0c6c379a54fdf2d1.zip | |
* net/tramp.el (top): Quote feature names. Remove
`tramp-rfn-eshadow-setup-minibuffer' from
`rfn-eshadow-setup-minibuffer-hook' when unloading.
(tramp-read-passwd): There is only one call to
`auth-source-user-or-password' needed. Pacify byte compiler.
| -rw-r--r-- | lisp/ChangeLog | 10 | ||||
| -rw-r--r-- | lisp/net/tramp.el | 24 |
2 files changed, 22 insertions, 12 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8a5b4058b5e..3cef51e02d8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,13 @@ | |||
| 1 | 2008-06-08 Michael Albinus <michael.albinus@gmx.de> | ||
| 2 | |||
| 3 | * uniquify.el (uniquify-get-proposed-name): Handle remote files. | ||
| 4 | |||
| 5 | * net/tramp.el (top): Quote feature names. Remove | ||
| 6 | `tramp-rfn-eshadow-setup-minibuffer' from | ||
| 7 | `rfn-eshadow-setup-minibuffer-hook' when unloading. | ||
| 8 | (tramp-read-passwd): There is only one call to | ||
| 9 | `auth-source-user-or-password' needed. Pacify byte compiler. | ||
| 10 | |||
| 1 | 2008-06-08 Andreas Schwab <schwab@suse.de> | 11 | 2008-06-08 Andreas Schwab <schwab@suse.de> |
| 2 | 12 | ||
| 3 | * window.el (display-buffer): Use lru window if current window | 13 | * window.el (display-buffer): Use lru window if current window |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index a026b45c4d2..546bb69b02f 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -144,8 +144,8 @@ | |||
| 144 | (require feature) | 144 | (require feature) |
| 145 | (add-hook 'tramp-unload-hook | 145 | (add-hook 'tramp-unload-hook |
| 146 | `(lambda () | 146 | `(lambda () |
| 147 | (when (featurep ,feature) | 147 | (when (featurep (quote ,feature)) |
| 148 | (unload-feature ,feature 'force))))))) | 148 | (unload-feature (quote ,feature) 'force))))))) |
| 149 | 149 | ||
| 150 | ;;; User Customizable Internal Variables: | 150 | ;;; User Customizable Internal Variables: |
| 151 | 151 | ||
| @@ -2094,7 +2094,11 @@ special handling of `substitute-in-file-name'." | |||
| 2094 | 2094 | ||
| 2095 | (when (boundp 'rfn-eshadow-setup-minibuffer-hook) | 2095 | (when (boundp 'rfn-eshadow-setup-minibuffer-hook) |
| 2096 | (add-hook 'rfn-eshadow-setup-minibuffer-hook | 2096 | (add-hook 'rfn-eshadow-setup-minibuffer-hook |
| 2097 | 'tramp-rfn-eshadow-setup-minibuffer)) | 2097 | 'tramp-rfn-eshadow-setup-minibuffer) |
| 2098 | (add-hook 'tramp-unload-hook | ||
| 2099 | '(lambda () | ||
| 2100 | (remove-hook 'rfn-eshadow-setup-minibuffer-hook | ||
| 2101 | 'tramp-rfn-eshadow-setup-minibuffer)))) | ||
| 2098 | 2102 | ||
| 2099 | (defun tramp-rfn-eshadow-update-overlay () | 2103 | (defun tramp-rfn-eshadow-update-overlay () |
| 2100 | "Update `rfn-eshadow-overlay' to cover shadowed part of minibuffer input. | 2104 | "Update `rfn-eshadow-overlay' to cover shadowed part of minibuffer input. |
| @@ -7218,16 +7222,12 @@ Invokes `password-read' if available, `read-passwd' else." | |||
| 7218 | (format "%s for %s " (capitalize (match-string 1)) key))))) | 7222 | (format "%s for %s " (capitalize (match-string 1)) key))))) |
| 7219 | 7223 | ||
| 7220 | (or | 7224 | (or |
| 7221 | ;; see if auth-sources contains something useful, if it's bound | 7225 | ;; See if auth-sources contains something useful, if it's bound. |
| 7222 | (when (boundp 'auth-sources) | 7226 | (when (boundp 'auth-sources) |
| 7223 | (or | 7227 | ;; Try with Tramp's current method. |
| 7224 | ;; 1. try with Tramp's current method | 7228 | (funcall (symbol-function 'auth-source-user-or-password) |
| 7225 | (auth-source-user-or-password | 7229 | "password" tramp-current-host tramp-current-method)) |
| 7226 | "password" tramp-current-host tramp-current-method) | 7230 | ;; Else, get the password interactively. |
| 7227 | ;; 2. hard-code the method to be "tramp" | ||
| 7228 | (auth-source-user-or-password | ||
| 7229 | "password" tramp-current-host "tramp"))) | ||
| 7230 | ;; 3. else, get the password interactively | ||
| 7231 | (if (functionp 'password-read) | 7231 | (if (functionp 'password-read) |
| 7232 | (let ((password (funcall (symbol-function 'password-read) | 7232 | (let ((password (funcall (symbol-function 'password-read) |
| 7233 | pw-prompt key))) | 7233 | pw-prompt key))) |