Skip to content

Commit 22600a2

Browse files
Eric WongJunio C Hamano
authored andcommitted
git-svn: do not let Git.pm warn if we prematurely close pipes
This mainly quiets down warnings when running git svn log. Signed-off-by: Eric Wong <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1e5db30 commit 22600a2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

git-svn.perl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -681,7 +681,7 @@ sub show_log {
681681
process_commit($_, $r_min, $r_max) foreach reverse @k;
682682
}
683683
out:
684-
eval { command_close_pipe($log) };
684+
close $log;
685685
print '-' x72,"\n" unless $_incremental || $_oneline;
686686
}
687687

@@ -1475,7 +1475,7 @@ sub map_tree_joins {
14751475
$seen{$commit} = 1;
14761476
}
14771477
}
1478-
eval { command_close_pipe($pipe) };
1478+
close $pipe;
14791479
}
14801480
}
14811481

@@ -1669,7 +1669,7 @@ sub write_grafts {
16691669
last unless /^\S/;
16701670
}
16711671
}
1672-
eval { command_close_pipe($ch) }; # breaking the pipe
1672+
close $ch; # breaking the pipe
16731673

16741674
# if real parents are the only ones in the grafts, drop it
16751675
next if join(' ',sort keys %$p) eq join(' ',sort keys %x);
@@ -1766,7 +1766,7 @@ sub get_commit_time {
17661766
} elsif ($tz =~ s/^\-//) {
17671767
$s -= tz_to_s_offset($tz);
17681768
}
1769-
eval { command_close_pipe($fh) };
1769+
close $fh;
17701770
return $s;
17711771
}
17721772
die "Can't get commit time for commit: $cmt\n";
@@ -2846,7 +2846,7 @@ sub rmdirs {
28462846
delete $rm->{join '/', @dn};
28472847
}
28482848
unless (%$rm) {
2849-
eval { command_close_pipe($fh) };
2849+
close $fh;
28502850
return;
28512851
}
28522852
}

0 commit comments

Comments
 (0)