projects
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e2860ea
)
gitweb: PATH_INFO=/ means no project
author
Jakub Narebski
<jnareb@gmail.com>
Sat, 5 Aug 2006 11:16:03 +0000
(13:16 +0200)
committer
Junio C Hamano
<junkio@cox.net>
Sun, 6 Aug 2006 08:59:45 +0000
(
01:59
-0700)
Prepared for refactoring input validation.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
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 2e2629ca53dcb67a78bfb62333b06181a435bd41..fdba15e2b23c4d80e6bb73d8a73a16c12f4a09a5 100755
(executable)
--- a/
gitweb/gitweb.perl
+++ b/
gitweb/gitweb.perl
@@
-86,8
+86,8
@@
if (defined $action) {
}
our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});
-if (defined $project) {
- $project =~ s|^/||; $project =~ s|/$||;
+$project =~ s|^/||; $project =~ s|/$||;
+if (defined $project && $project) {
if (!validate_input($project)) {
die_error(undef, "Invalid project parameter");
}