X-Git-Url: https://git.ladys.computer/Gitweb/blobdiff_plain/eded4441e852836fd424bc74512462ebae07d94622bafcbcd6fe3ea19cd983de..71ed299c857d269044a89a950c36fc5146dc0c470b834eb67f908a3c8c4c8b6b:/gitweb.perl diff --git a/gitweb.perl b/gitweb.perl index 52e3461..43bf744 100755 --- a/gitweb.perl +++ b/gitweb.perl @@ -1115,7 +1115,9 @@ sub git_get_project_description { open my $fd, "$projectroot/$path/description" or return undef; my $descr = <$fd>; close $fd; - chomp $descr; + if (defined $descr) { + chomp $descr; + } return $descr; } @@ -2721,8 +2723,9 @@ sub git_patchset_body { delete $from{'href'}; } } + $to{'file'} = $diffinfo->{'to_file'} || $diffinfo->{'file'}; - if ($diffinfo->{'status'} ne "D") { # not deleted file + if ($diffinfo->{'to_id'} ne ('0' x 40)) { # file exists in result $to{'href'} = href(action=>"blob", hash_base=>$hash, hash=>$diffinfo->{'to_id'}, file_name=>$to{'file'}); @@ -2878,7 +2881,14 @@ sub git_patchset_body { } continue { print "\n"; # class="patch" } - print "