$OpenBSD: patch-gitweb_gitweb_perl,v 1.27 2016/05/25 07:13:05 benoit Exp $

This prevents the following error: '-T and -B not implemented on filehandles'

--- gitweb/gitweb.perl.orig	Thu May 19 19:17:58 2016
+++ gitweb/gitweb.perl	Wed May 25 08:57:20 2016
@@ -6988,7 +6988,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)
@@ -7050,7 +7050,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
