author | Jakub Narebski <jnareb@gmail.com> | |
Sat, 12 May 2007 10:42:32 +0000 (12:42 +0200) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sat, 12 May 2007 16:19:08 +0000 (09:19 -0700) | ||
commit | 2206537c07973fc2933092313d95340e076440e4 | |
tree | 51cab266407b12fb1ba6b43ef789c5edd10c3304 | tree | snapshot |
parent | 93c44d493b8c98b9bb74e4f78aa90ee20a01f078 | commit | diff |
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 <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
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 <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
gitweb/gitweb.perl | diff | blob | history |