author | Jakub Narebski <jnareb@gmail.com> | |
Sun, 10 May 2009 00:38:34 +0000 (02:38 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 11 May 2009 04:18:49 +0000 (21:18 -0700) | ||
commit | dff2b6d4842eef0a03a3c8b3761f72e2b55b609e | |
tree | fafc33fe52eac4fef8d5793b2d0dd43788ee426c | tree | snapshot |
parent | ad87e4f6f19e78b3f2d7dde3d3ed403db4f79a03 | commit | diff |
gitweb: Always use three argument form of open
In most cases (except insert_file() subroutine) we used old two argument
form of 'open' to open files for reading. This can cause subtle bugs when
$projectroot or $projects_list file starts with mode characters ('>', '<',
'+<', '|', etc.) or with leading whitespace; and also when $projects_list
file or $mimetypes_file or ctags files end with trailing whitespace or '|'.
Additionally it is also more clear to explicitly state that we open those
files for reading.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
In most cases (except insert_file() subroutine) we used old two argument
form of 'open' to open files for reading. This can cause subtle bugs when
$projectroot or $projects_list file starts with mode characters ('>', '<',
'+<', '|', etc.) or with leading whitespace; and also when $projects_list
file or $mimetypes_file or ctags files end with trailing whitespace or '|'.
Additionally it is also more clear to explicitly state that we open those
files for reading.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
gitweb/gitweb.perl | diff | blob | history |