JavaScriptCore:
Reviewed by Geoff.
- test for http://bugs.webkit.org/show_bug.cgi?id=16458
REGRESSION (r28164): regular expressions can now hang due to lack of a match limit
<rdar://problem/
5636067>
Test: fast/regex/slow.html
Slows down SunSpider a bit (about 1.01x); filed a bug to follow up on that:
http://bugs.webkit.org/show_bug.cgi?id=16503
* pcre/pcre.h: Changed name of error code to not specifically mention "recursion".
* pcre/pcre_exec.cpp:
(match): Replaced the depth limit, MATCH_RECURSION_LIMIT, with a total match looping
limit, matchLimit. Also eliminated the constants for MATCH_MATCH and MATCH_NOMATCH,
since they are just true and false (1 and 0).
(jsRegExpExecute): More of the MATCH_MATCH change.
LayoutTests:
Reviewed by Geoff.
- test for http://bugs.webkit.org/show_bug.cgi?id=16458
REGRESSION (r28164): regular expressions can now hang due to lack of a match limit
* fast/regex/resources: Added.
* fast/regex/resources/TEMPLATE.html: Copied from fast/js/resources/TEMPLATE.html.
* fast/regex/resources/slow.js: Added.
* fast/regex/slow-expected.txt: Added.
* fast/regex/slow.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28833
268f45cc-cd09-0410-ab3c-
d52691b4dbfc