aboutsummaryrefslogtreecommitdiff
path: root/git-cvsimport.perl
diff options
context:
space:
mode:
authorMartin Langhoff <martin@catalyst.net.nz>2006-05-23 00:45:39 +1200
committerJunio C Hamano <junkio@cox.net>2006-05-22 18:16:44 -0700
commitc4b16f8d7786c2a9655636779ce4e3e89f0df86c (patch)
tree424367c86094acd2d787f018ba5bbf1945ad6c16 /git-cvsimport.perl
parentf396f01f11208789875b61e4e0e3239b04f9e38d (diff)
downloadgit-c4b16f8d7786c2a9655636779ce4e3e89f0df86c.tar.gz
git-c4b16f8d7786c2a9655636779ce4e3e89f0df86c.tar.xz
cvsimport: replace anonymous sub ref with a normal sub
commit() does not need to be an anonymous subreference. Keep it simple. Signed-off-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'git-cvsimport.perl')
-rwxr-xr-xgit-cvsimport.perl6
1 files changed, 3 insertions, 3 deletions
diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index 282646af3..d257e668d 100755
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
@@ -563,7 +563,7 @@ my $state = 0;
my($patchset,$date,$author_name,$author_email,$branch,$ancestor,$tag,$logmsg);
my(@old,@new,@skipped);
-my $commit = sub {
+sub commit {
my $pid;
while(@old) {
my @o2;
@@ -852,7 +852,7 @@ while(<CVS>) {
} elsif($state == 9 and /^\s*$/) {
$state = 10;
} elsif(($state == 9 or $state == 10) and /^-+$/) {
- &$commit();
+ commit();
$state = 1;
} elsif($state == 11 and /^-+$/) {
$state = 1;
@@ -862,7 +862,7 @@ while(<CVS>) {
print "* UNKNOWN LINE * $_\n";
}
}
-&$commit() if $branch and $state != 11;
+commit() if $branch and $state != 11;
unlink($git_index);