httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject svn commit: r1773885 - /httpd/test/framework/trunk/t/apache/expr.t
Date Mon, 12 Dec 2016 21:58:18 GMT
Author: wrowe
Date: Mon Dec 12 21:58:18 2016
New Revision: 1773885

URL: http://svn.apache.org/viewvc?rev=1773885&view=rev
Log:
Ensure pcre doesn't choke when given too many matches

Modified:
    httpd/test/framework/trunk/t/apache/expr.t

Modified: httpd/test/framework/trunk/t/apache/expr.t
URL: http://svn.apache.org/viewvc/httpd/test/framework/trunk/t/apache/expr.t?rev=1773885&r1=1773884&r2=1773885&view=diff
==============================================================================
--- httpd/test/framework/trunk/t/apache/expr.t (original)
+++ httpd/test/framework/trunk/t/apache/expr.t Mon Dec 12 21:58:18 2016
@@ -80,6 +80,8 @@ my @test_cases = (
     # $0 .. $9 are only populated if there are capturing parens
     [ q[ 'abc' =~ /bc/ && $0 == '' ]                    => 1 ],
     [ q[ 'abc' =~ /(bc)/ && 'xy' =~ /x/ && $0 == 'bc' ] => 1 ],
+    # Attempt to blow up when more matches are present than 'typical' $0 .. $9 
+    [ q[ 'abcdefghijklm' =~ /(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)/ && $2 == 'c' ] =>
1 ],
     # variables
     [ q[%{TIME_YEAR} =~ /^\d{4}$/]               => 1 ],
     [ q[%{TIME_YEAR} =~ /^\d{3}$/]               => 0 ],



Mime
View raw message