From 61efa5e300386978dd440716260c94e951a493b4 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 23 May 2006 16:30:39 -0700 Subject: [PATCH] cvsimport: do not barf on creation of an empty file. When the server says "created this file whose length is empty", we mistakenly said "oops, the server did not say a sensible thing". Fix it. Spotted and fixed by Linus, acked by Martin. Signed-off-by: Junio C Hamano --- git-cvsimport.perl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-cvsimport.perl b/git-cvsimport.perl index 41ee9a60..60fc86a5 100755 --- a/git-cvsimport.perl +++ b/git-cvsimport.perl @@ -371,7 +371,7 @@ sub file { } sub _fetchfile { my ($self, $fh, $cnt) = @_; - my $res; + my $res = 0; my $bufsize = 1024 * 1024; while($cnt) { if ($bufsize > $cnt) { -- 2.11.0