diff options
| -rw-r--r-- | lisp/net/tramp.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 52a4be863c7..af08cf7e13a 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -4218,7 +4218,8 @@ Invokes `password-read' if available, `read-passwd' else." | |||
| 4218 | (setq auth-info | 4218 | (setq auth-info |
| 4219 | (auth-source-search | 4219 | (auth-source-search |
| 4220 | :max 1 | 4220 | :max 1 |
| 4221 | :user (or tramp-current-user t) | 4221 | (and tramp-current-user :user) |
| 4222 | tramp-current-user | ||
| 4222 | :host tramp-current-host | 4223 | :host tramp-current-host |
| 4223 | :port tramp-current-method | 4224 | :port tramp-current-method |
| 4224 | :require | 4225 | :require |
| @@ -4262,7 +4263,7 @@ Invokes `password-read' if available, `read-passwd' else." | |||
| 4262 | ;; since Emacs 24.1, it has been replaced by `auth-source-forget'. | 4263 | ;; since Emacs 24.1, it has been replaced by `auth-source-forget'. |
| 4263 | (if (fboundp 'auth-source-forget) | 4264 | (if (fboundp 'auth-source-forget) |
| 4264 | (auth-source-forget | 4265 | (auth-source-forget |
| 4265 | `(:max 1 :user ,(or user t) :host ,host :port ,method)) | 4266 | `(:max 1 ,(and user :user) ,user :host ,host :port ,method)) |
| 4266 | (tramp-compat-funcall | 4267 | (tramp-compat-funcall |
| 4267 | 'auth-source-forget-user-or-password "password" host method)) | 4268 | 'auth-source-forget-user-or-password "password" host method)) |
| 4268 | (password-cache-remove (tramp-make-tramp-file-name method user host "")))) | 4269 | (password-cache-remove (tramp-make-tramp-file-name method user host "")))) |