[Rt-commit] rt branch, 4.0/tab-canonicalize-request-path, created. rt-4.0.5-117-g86d60bf
? sunnavy
sunnavy at bestpractical.com
Thu Apr 12 11:52:17 EDT 2012
The branch, 4.0/tab-canonicalize-request-path has been created
at 86d60bf4838420f0c5afbadfd074e240d1b9190b (commit)
- Log -----------------------------------------------------------------
commit 86d60bf4838420f0c5afbadfd074e240d1b9190b
Author: sunnavy <sunnavy at bestpractical.com>
Date: Thu Apr 12 23:45:48 2012 +0800
canonicalize away multiple leading slashes
as we match the request path by m{^/...} in the following code,
this canonizalization helps when user uses interesting urls
like //Ticket/Display.html
see #19723
diff --git a/share/html/Elements/Tabs b/share/html/Elements/Tabs
index f65f909..3d30347 100755
--- a/share/html/Elements/Tabs
+++ b/share/html/Elements/Tabs
@@ -50,6 +50,7 @@
<%INIT>
my $request_path = $HTML::Mason::Commands::r->path_info;
+$request_path =~ s!^/{2,}!/!;
my $query_string = sub {
my %args = @_;
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list