Do not scramble password read from .cvspass
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>
Pascal Obry committed
Sep 4, 2009 at 13:58 UTC
3fb9d58235ce4985689840b901aecacc6e3bd094
1 file changed
+3
-3
git-cvsimport.perl
+3
-3
@@ -238,7 +238,9 @@ sub conn {
238
}
239
my $rr = ":pserver:$user\@$serv:$port$repo";
240
241
- unless ($pass) {
241
+ if ($pass) {
242
+ $pass = $self->_scramble($pass);
243
+ } else {
244
open(H,$ENV{'HOME'}."/.cvspass") and do {
245
# :pserver:cvs@mea.tmt.tele.fi:/cvsroot/zmailer Ah<Z
246
while (<H>) {
@@ -253,8 +255,6 @@ sub conn {
255
};
256
}
257
256
- $pass = $self->_scramble($pass);
257
-
258
my ($s, $rep);
259
if ($proxyhost) {
260