diff options
author | Eric Wong <e@yhbt.net> | 2020-01-11 22:34:56 +0000 |
---|---|---|
committer | Eric Wong <e@yhbt.net> | 2020-01-13 04:36:38 +0000 |
commit | 6d8658803b0f75ccdc54d16c8fda4e2cfaed0388 (patch) | |
tree | 520e21c83af9149a415f5afa2e2d63365200178d | |
parent | 7778d7abd5acb2ba7c32de10cec1369f3982bf84 (diff) | |
download | public-inbox-6d8658803b0f75ccdc54d16c8fda4e2cfaed0388.tar.gz |
While v1 inboxes typically only have one branch, code repositories may have dozens or even hundreds. Slurping those into memory is a waste.
-rw-r--r-- | lib/PublicInbox/Git.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/Git.pm b/lib/PublicInbox/Git.pm index 8ee04e17..0ace907e 100644 --- a/lib/PublicInbox/Git.pm +++ b/lib/PublicInbox/Git.pm @@ -347,7 +347,7 @@ sub modified ($) { my $fh = popen($self, qw(rev-parse --branches)); cat_async_begin($self); local $/ = "\n"; - foreach my $oid (<$fh>) { + while (my $oid = <$fh>) { chomp $oid; cat_async($self, $oid, \&extract_cmt_time, \$modified); } |