From bd3625c432ee3d05ae4316d3b0ad2c0225e6d532 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sat, 22 Nov 2014 17:04:47 +0100 Subject: [PATCH] Fixes: debbugs:19047 * net/tramp.el (tramp-action-password): Clean password on subsequent attempts even if there was no wrong password indication. --- lisp/ChangeLog | 3 +++ lisp/net/tramp.el | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 148d77ffa9c..0f16eabdc03 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2014-11-22 Michael Albinus + * net/tramp.el (tramp-action-password): Clean password on subsequent + attempts even if there was no wrong password indication. (Bug#19047) + * net/tramp-sh.el (tramp-get-remote-locale): Return "LC_ALL=C" as fallback. (tramp-open-connection-setup-interactive-shell): No need to check diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 085b527a57f..fc9950d4a69 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -3445,9 +3445,9 @@ of." ;; Let's check whether a wrong password has been sent already. ;; Sometimes, the process returns a new password request ;; immediately after rejecting the previous (wrong) one. - (goto-char (point-min)) - (when (search-forward-regexp tramp-wrong-passwd-regexp nil t) + (unless (tramp-get-connection-property vec "first-password-request" nil) (tramp-clear-passwd vec)) + (goto-char (point-min)) (tramp-check-for-regexp proc tramp-password-prompt-regexp) (tramp-message vec 3 "Sending %s" (match-string 1)) ;; We don't call `tramp-send-string' in order to hide the -- 2.11.4.GIT