Skip to content

Commit

Permalink
Do not scramble password read from .cvspass
Browse files Browse the repository at this point in the history
Passwords stored in .cvspass are already scrambled, we do not
want to scramble them twice. Only passwords read from the
command line are scrambled.

This fixes a regression introduced by b2139db (git-cvsimport: add support
for cvs pserver password scrambling., 2009-08-14).

Signed-off-by: Pascal Obry <pascal@obry.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Pascal Obry authored and Junio C Hamano committed Sep 6, 2009
1 parent 79b4fde commit 3fb9d58
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions git-cvsimport.perl
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,9 @@ sub conn {
}
my $rr = ":pserver:$user\@$serv:$port$repo";

unless ($pass) {
if ($pass) {
$pass = $self->_scramble($pass);
} else {
open(H,$ENV{'HOME'}."/.cvspass") and do {
# :pserver:cvs@mea.tmt.tele.fi:/cvsroot/zmailer Ah<Z
while (<H>) {
Expand All @@ -253,8 +255,6 @@ sub conn {
};
}

$pass = $self->_scramble($pass);

my ($s, $rep);
if ($proxyhost) {

Expand Down

0 comments on commit 3fb9d58

Please sign in to comment.