about summary refs log tree commit homepage
path: root/lib/PublicInbox/Import.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-07-27 22:28:26 +0000
committerEric Wong <e@80x24.org>2016-07-27 22:28:51 +0000
commite0b7cf5eb5e6828d07094fa44be67e2d7d63e722 (patch)
tree7e83f74f701cdbf5e6a31520871ab1457813555d /lib/PublicInbox/Import.pm
parent6cf4ed00cfe766141572511d4ab2016cd6dafe46 (diff)
downloadpublic-inbox-e0b7cf5eb5e6828d07094fa44be67e2d7d63e722.tar.gz
Callers may have localized $/ to something else, so make sure
we chomp the expected character(s) when calling chomp.
Diffstat (limited to 'lib/PublicInbox/Import.pm')
-rw-r--r--lib/PublicInbox/Import.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/PublicInbox/Import.pm b/lib/PublicInbox/Import.pm
index 27f36a7e..bb0811a5 100644
--- a/lib/PublicInbox/Import.pm
+++ b/lib/PublicInbox/Import.pm
@@ -38,6 +38,7 @@ sub gfi_start {
 
         # wait for other processes to be done
         flock($lockfh, LOCK_EX) or die "lock failed: $!\n";
+        local $/ = "\n";
         chomp($self->{tip} = $git->qx(qw(rev-parse --revs-only), $self->{ref}));
 
         my @cmd = ('git', "--git-dir=$git_dir", qw(fast-import