summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9567685)
raw | patch | inline | side by side (parent: 9567685)
author | Aneesh Kumar K.V <aneesh.kumar@gmail.com> | |
Fri, 1 Sep 2006 03:43:32 +0000 (09:13 +0530) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Fri, 1 Sep 2006 04:10:17 +0000 (21:10 -0700) |
Signed-off-by: Junio C Hamano <junkio@cox.net>
gitweb/gitweb.perl | patch | blob | history |
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 0984e856235bcfe5e93c74504b605169d1b65daf..57ffa25070984f6ca3310c83062ac8dcd68d30fc 100755 (executable)
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
my $fd;
my $ftype;
- if (!gitweb_check_feature('blame')) {
+ my ($have_blame) = gitweb_check_feature('blame');
+ if (!$have_blame) {
die_error('403 Permission denied', "Permission denied");
}
die_error('404 Not Found', "File name not defined") if (!$file_name);
sub git_blame {
my $fd;
- if (!gitweb_check_feature('blame')) {
+ my ($have_blame) = gitweb_check_feature('blame');
+ if (!$have_blame) {
die_error('403 Permission denied', "Permission denied");
}
die_error('404 Not Found', "File name not defined") if (!$file_name);
die_error(undef, "No file name defined");
}
}
- my $have_blame = gitweb_check_feature('blame');
+ my ($have_blame) = gitweb_check_feature('blame');
open my $fd, "-|", git_cmd(), "cat-file", "blob", $hash
or die_error(undef, "Couldn't cat $file_name, $hash");
my $mimetype = blob_mimetype($fd, $file_name);
my $ref = format_ref_marker($refs, $hash_base);
git_header_html();
my $base = "";
- my $have_blame = gitweb_check_feature('blame');
+ my ($have_blame) = gitweb_check_feature('blame');
if (defined $hash_base && (my %co = parse_commit($hash_base))) {
git_print_page_nav('tree','', $hash_base);
git_print_header_div('commit', esc_html($co{'title'}) . $ref, $hash_base);