[PATCH] gitweb: reset input record separator in parse_commit even on error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---
This probably never happens, but just in case...

 gitweb/gitweb.perl |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 7afdf33..60dd598 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -897,8 +897,8 @@ sub parse_commit {
 		my $fd = git_pipe("rev-list", "--header", "--parents", "--max-count=1", $commit_id)
 			or return;
 		@commit_lines = split '\n', <$fd>;
-		close $fd or return;
 		$/ = "\n";
+		close $fd or return;
 		pop @commit_lines;
 	}
 	my $header = shift @commit_lines;
-- 
0.99.8c.g64e8-dirty

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]