]> Lady’s Gitweb - Gitweb/commit
gitweb: Test if $from_id and $to_id are defined before comparison
authorJakub Narebski <redacted>
Sat, 12 May 2007 10:42:32 +0000 (12:42 +0200)
committerLady <redacted>
Mon, 6 Apr 2026 04:07:11 +0000 (00:07 -0400)
commitda326cf3632cb9fe5806c1e9218155f79e93b2f61a9a1a21280b0056d8c2c106
treea226dce39f28e77b574ba9e2b7932c5a729f23898f1edcfa40d985f220468272
parent9a440da9df4548adb90d120e8857eebf4faa11ac793a19e00a42eb616a666b1c
gitweb: Test if $from_id and $to_id are defined before comparison

Get rid of "Use of uninitialized value in string eq at
gitweb/gitweb.perl line 2320" warning caused by the fact that "empty"
patches, consisting only of extended git diff header and with patch
body empty, such as patch for pure rename, does not have "index" line
in extended diff header.  For such patches $from_id and $to_id, filled
from parsing extended diff header, are undefined.  But such patches
cannot be continuation patches.

Test if $from_id and $to_id are defined before comparing them with
$diffinfo.

Signed-off-by: Jakub Narebski <redacted>
Signed-off-by: Junio C Hamano <redacted>
gitweb.perl
This page took 0.197854 seconds and 4 git commands to generate.