openbsd-ports/devel/git/patches/patch-gitweb_gitweb_perl
dcoppa dc6e734779 Bugfix update to git-1.8.0.3
OK benoit@ (maintainer)
2013-01-01 18:35:42 +00:00

25 lines
955 B
Plaintext

$OpenBSD: patch-gitweb_gitweb_perl,v 1.20 2013/01/01 18:35:42 dcoppa Exp $
This prevents the following error: '-T and -B not implemented on filehandles'
--- gitweb/gitweb.perl.orig Fri Dec 28 01:32:43 2012
+++ gitweb/gitweb.perl Sun Dec 30 13:43:13 2012
@@ -6892,7 +6892,7 @@ sub git_blob_plain {
$expires = "+1d";
}
- open my $fd, "-|", git_cmd(), "cat-file", "blob", $hash
+ open my $fd, "-|:raw:perlio", git_cmd(), "cat-file", "blob", $hash
or die_error(500, "Open git-cat-file blob '$hash' failed");
# content-type (can include charset)
@@ -6954,7 +6954,7 @@ sub git_blob {
}
my $have_blame = gitweb_check_feature('blame');
- open my $fd, "-|", git_cmd(), "cat-file", "blob", $hash
+ open my $fd, "-|:raw:perlio", git_cmd(), "cat-file", "blob", $hash
or die_error(500, "Couldn't cat $file_name, $hash");
my $mimetype = blob_mimetype($fd, $file_name);
# use 'blob_plain' (aka 'raw') view for files that cannot be displayed