From: Sven Strickroth Date: Tue, 27 Dec 2011 16:06:07 GMT Subject: [PATCH 2/5] switch to central prompt method Message-ID: <4EF9ECEF.6020403@tu-clausthal.de> In-Reply-To: <4EF9EBF4.7070200@tu-clausthal.de> Signed-off-by: Sven Strickroth --- git-svn.perl | 9 ++------- 1 files changed, 2 insertions(+), 7 deletions(-) diff --git a/git-svn.perl b/git-svn.perl index eeb83d3..25d5da7 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -4415,13 +4415,8 @@ sub username { sub _read_password { my ($prompt, $realm) = @_; - my $password = ''; - if (exists $ENV{GIT_ASKPASS}) { - open(PH, "-|", $ENV{GIT_ASKPASS}, $prompt); - $password = ; - $password =~ s/[\012\015]//; # \n\r - close(PH); - } else { + my $password = Git->askpass_prompt($prompt);; + if (!defined $password) { print STDERR $prompt; STDERR->flush; require Term::ReadKey; -- Best regards, Sven Strickroth ClamAV, a GPL anti-virus toolkit http://www.clamav.net PGP key id F5A9D4C4 @ any key-server