perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Fred Moyer <f...@taperfriendlymusic.org>
Subject [patch] fix unescaped variable interprolation in regular expression
Date Fri, 23 Mar 2007 04:16:32 GMT
I have a +1 from Phillip [1](mp2 patch), another?

[1] http://marc.info/?l=apache-modperl&m=117462227916610&w=2

Index: Changes
===================================================================
--- Changes     (revision 521567)
+++ Changes     (working copy)
@@ -10,6 +10,9 @@

  =item 1.30_01-dev

+fix unescaped variable interprolation in regular expression
+[Randal L. Schwartz <merlyn@stonehenge.com>, Fred Moyer 
<fred@redhotpenguin.com>]
+
  Pull in the new Apache-SizeLimit from
  http://svn.apache.org/repos/asf/perl/Apache-SizeLimit/trunk
  and obsolete the previous lib/Apache/SizeLimit.pm.
Index: lib/Apache/PerlRun.pm
===================================================================
--- lib/Apache/PerlRun.pm       (revision 521567)
+++ lib/Apache/PerlRun.pm       (working copy)
@@ -168,7 +168,7 @@
                   $uri) if $Debug && $Debug & 4;

      my $path_info = $r->path_info;
-    my $script_name = $path_info && $uri =~ /$path_info$/ ?
+    my $script_name = $path_info && $uri =~ /\Q$path_info\E$/ ?
         substr($uri, 0, length($uri)-length($path_info)) :
         $uri;

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message