Fix two issues in JIT.

This commit is contained in:
Zoltán Herczeg 2015-09-02 08:35:50 +00:00
parent cdf07ab585
commit 357dfb7964
4 changed files with 20 additions and 6 deletions

View File

@ -169,6 +169,9 @@ commas.
48. Implemented PCRE2_ALT_VERBNAMES.
49. Fixed two issues in JIT. These were found by Karl Skomski with a custom
LLVM fuzzer.
Version 10.20 30-June-2015
--------------------------

View File

@ -3748,6 +3748,7 @@ while (TRUE)
}
}
while (chars[0] != 255 && bytes < bytes_end);
bytes = bytes_end - 32;
}
consumed++;
@ -9508,7 +9509,6 @@ while (cc < ccend)
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), STR_PTR, 0);
}
BACKTRACK_AS(braminzero_backtrack)->matchingpath = LABEL();
if (cc[1] > OP_ASSERTBACK_NOT)
count_match(common);
break;

View File

@ -249,4 +249,9 @@
/(x(?1)){4}/
/[axm]{7}/
/(.|.)*?bx/
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabax
# End of testinput17

14
testdata/testoutput17 vendored
View File

@ -198,7 +198,7 @@ May match empty string
Subject length lower bound = 0
JIT compilation was successful
/* this is a C style comment */\=find_limits
Minimum match limit = 1
Minimum match limit = 29
0: /* this is a C style comment */ (JIT)
1: /* this is a C style comment */
@ -222,17 +222,17 @@ Minimum match limit = 1
/a(?:.)*?a/ims
abbbbbbbbbbbbbbbbbbbbba\=find_limits
Minimum match limit = 1
Minimum match limit = 22
0: abbbbbbbbbbbbbbbbbbbbba (JIT)
/a(?:.(*THEN))*?a/ims
abbbbbbbbbbbbbbbbbbbbba\=find_limits
Minimum match limit = 1
Minimum match limit = 22
0: abbbbbbbbbbbbbbbbbbbbba (JIT)
/a(?:.(*THEN:ABC))*?a/ims
abbbbbbbbbbbbbbbbbbbbba\=find_limits
Minimum match limit = 1
Minimum match limit = 22
0: abbbbbbbbbbbbbbbbbbbbba (JIT)
/^(?>a+)(?>b+)(?>c+)(?>d+)(?>e+)/
@ -483,4 +483,10 @@ Failed: error -46: JIT stack limit reached
/(x(?1)){4}/
/[axm]{7}/
/(.|.)*?bx/
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabax
Failed: error -47: match limit exceeded
# End of testinput17