Branch Coverage

deps/libgit2/deps/pcre/pcre_exec.c
Criterion Covered Total %
branch 154 1902 8.1


line true false branch
190 0 0 if (length < 0) return -1;
196 0 0 if (caseless)
236 0 0 while (length-- > 0)
239 0 0 if (eptr >= md->end_subject) return -2; /* Partial match */
242 0 0 if (TABLE_GET(cp, md->lcc, cp) != TABLE_GET(cc, md->lcc, cc)) return -1;
254 0 0 while (length-- > 0)
256 0 0 if (eptr >= md->end_subject) return -2; /* Partial match */
257 0 0 if (UCHAR21INCTEST(p) != UCHAR21INCTEST(eptr)) return -1;
666 0 153 if (ecode == NULL)
668 0 0 if (rdepth == 0)
724 0 244 if (md->match_call_count++ >= md->match_limit) RRETURN(PCRE_ERROR_MATCHLIMIT);
725 0 244 if (rdepth >= md->match_limit_recursion) RRETURN(PCRE_ERROR_RECURSIONLIMIT);
739 0 244 if (md->match_function_type == MATCH_CBEGROUP)
761 0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
771 0 0 else if (rrc == MATCH_SKIP_ARG &&
0 0 else if (rrc == MATCH_SKIP_ARG &&
785 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
791 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
799 0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
801 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
807 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
821 0 0 if (md->skip_arg_count <= md->ignore_skip_arg)
828 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
845 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
854 0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
0 0 if ((rrc == MATCH_MATCH || rrc == MATCH_ACCEPT) &&
856 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
880 0 0 if (rrc == MATCH_MATCH) /* Note: _not_ MATCH_ACCEPT */
885 0 0 if (rrc == MATCH_THEN)
888 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
889 0 0 (*ecode == OP_ALT || *next == OP_ALT))
893 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
897 0 0 while (*ecode == OP_ALT);
901 0 0 if (*ecode != OP_ONCE_NC && *ecode != OP_ALT) RRETURN(MATCH_NOMATCH);
0 0 if (*ecode != OP_ONCE_NC && *ecode != OP_ALT) RRETURN(MATCH_NOMATCH);
906 0 0 do ecode += GET(ecode, 1); while (*ecode == OP_ALT);
916 0 0 if (*ecode == OP_KET || eptr == saved_eptr)
0 0 if (*ecode == OP_KET || eptr == saved_eptr)
926 0 0 if (*ecode == OP_KETRMIN)
929 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
936 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
968 0 10 if (offset < md->offset_max)
982 0 0 if (op >= OP_SBRA) md->match_function_type = MATCH_CBEGROUP;
985 0 0 if (rrc == MATCH_ONCE) break; /* Backing up through an atomic group */
998 0 0 if (rrc == MATCH_THEN)
1001 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1002 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1008 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1012 0 0 if (*ecode != OP_ALT) break;
1063 91 0 if (op >= OP_SBRA || op == OP_ONCE)
0 91 if (op >= OP_SBRA || op == OP_ONCE)
1070 91 0 else if (!md->hasthen && ecode[GET(ecode, 1)] != OP_ALT)
91 0 else if (!md->hasthen && ecode[GET(ecode, 1)] != OP_ALT)
1086 0 0 if (rrc == MATCH_THEN)
1089 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1090 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1094 0 0 if (rrc != MATCH_NOMATCH)
1096 0 0 if (rrc == MATCH_ONCE)
1099 0 0 if (*scode != OP_ONCE) /* If not at start, find it */
1101 0 0 while (*scode == OP_ALT) scode += GET(scode, 1);
1104 0 0 if (md->once_target == scode) rrc = MATCH_NOMATCH;
1110 0 0 if (*ecode != OP_ALT) break;
1139 0 0 if (offset >= md->offset_max) goto POSSESSIVE_NON_CAPTURE;
1164 0 0 if (op >= OP_SBRA) md->match_function_type = MATCH_CBEGROUP;
1167 0 0 if (rrc == MATCH_KETRPOS)
1174 0 0 if (eptr == md->end_match_ptr) /* Matched an empty string */
1176 0 0 do ecode += GET(ecode, 1); while (*ecode == OP_ALT);
1186 0 0 if (rrc == MATCH_THEN)
1189 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1190 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1194 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1197 0 0 if (*ecode != OP_ALT) break;
1200 0 0 if (!matched_once)
1207 0 0 if (allow_zero || matched_once)
0 0 if (allow_zero || matched_once)
1231 0 0 if (op >= OP_SBRA) md->match_function_type = MATCH_CBEGROUP;
1234 0 0 if (rrc == MATCH_KETRPOS)
1240 0 0 if (eptr == md->end_match_ptr) /* Matched an empty string */
1242 0 0 do ecode += GET(ecode, 1); while (*ecode == OP_ALT);
1252 0 0 if (rrc == MATCH_THEN)
1255 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1256 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1260 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1262 0 0 if (*ecode != OP_ALT) break;
1266 0 0 if (matched_once || allow_zero)
0 0 if (matched_once || allow_zero)
1294 0 0 if (*ecode == OP_CALLOUT)
1296 0 0 if (PUBL(callout) != NULL)
1317 0 0 if (cb.capture_last == 0) cb.capture_last = -1;
1320 0 0 if ((rrc = (*PUBL(callout))(&cb)) > 0) RRETURN(MATCH_NOMATCH);
1321 0 0 if (rrc < 0) RRETURN(rrc);
1337 0 0 if (md->recursive != NULL) /* Not recursing => FALSE */
1340 0 0 condition = (recno == RREF_ANY || recno == md->recursive->group_num);
0 0 condition = (recno == RREF_ANY || recno == md->recursive->group_num);
1345 0 0 if (md->recursive != NULL)
1349 0 0 while (count-- > 0)
1353 0 0 if (condition) break;
1361 0 0 condition = offset < offset_top && md->offset_vector[offset] >= 0;
0 0 condition = offset < offset_top && md->offset_vector[offset] >= 0;
1368 0 0 while (count-- > 0)
1371 0 0 condition = offset < offset_top && md->offset_vector[offset] >= 0;
0 0 condition = offset < offset_top && md->offset_vector[offset] >= 0;
1372 0 0 if (condition) break;
1389 0 0 if (rrc == MATCH_MATCH)
1391 0 0 if (md->end_offset_top > offset_top)
1400 0 0 if (*ecode == OP_BRAZERO) ecode++;
1402 0 0 while (*ecode == OP_ALT) ecode += GET(ecode, 1);
1410 0 0 else if (rrc != MATCH_NOMATCH && rrc != MATCH_THEN)
0 0 else if (rrc != MATCH_NOMATCH && rrc != MATCH_THEN)
1419 0 0 ecode += condition? PRIV(OP_lengths)[condcode] : codelink;
1431 0 0 if (condition || ecode[-(1+LINK_SIZE)] == OP_ALT)
0 0 if (condition || ecode[-(1+LINK_SIZE)] == OP_ALT)
1433 0 0 if (op != OP_SCOND)
1464 0 0 if (offset >= md->offset_max) md->capture_last |= OVFLBIT; else
1474 0 0 if (offset >= offset_top)
1478 0 0 while (iptr < iend) *iptr++ = -1;
1497 0 14 if (eptr == mstart && op != OP_ASSERT_ACCEPT &&
0 0 if (eptr == mstart && op != OP_ASSERT_ACCEPT &&
0 0 if (eptr == mstart && op != OP_ASSERT_ACCEPT &&
1498 0 0 md->recursive == NULL &&
1499 0 0 (md->notempty ||
1500 0 0 (md->notempty_atstart &&
1513 14 0 rrc = (op == OP_END)? MATCH_MATCH : MATCH_ACCEPT;
1530 0 0 if (md->match_function_type == MATCH_CONDASSERT)
1546 0 0 if (rrc == MATCH_MATCH || rrc == MATCH_ACCEPT)
0 0 if (rrc == MATCH_MATCH || rrc == MATCH_ACCEPT)
1559 0 0 if (rrc == MATCH_THEN)
1562 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1563 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1573 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1576 0 0 while (*ecode == OP_ALT); /* Continue for next alternative */
1581 0 0 if (*ecode == OP_KET) RRETURN(MATCH_NOMATCH);
1585 0 0 if (condassert) RRETURN(MATCH_MATCH);
1590 0 0 do ecode += GET(ecode,1); while (*ecode == OP_ALT);
1601 0 0 if (md->match_function_type == MATCH_CONDASSERT)
1629 0 0 if (md->start_match_ptr < next &&
0 0 if (md->start_match_ptr < next &&
1630 0 0 (*ecode == OP_ALT || *next == OP_ALT))
1646 0 0 do ecode += GET(ecode,1); while (*ecode == OP_ALT);
1659 0 0 while (*ecode == OP_ALT);
1664 0 0 if (condassert) RRETURN(MATCH_MATCH); /* Condition assertion */
1692 0 0 if (eptr < md->start_subject) RRETURN(MATCH_NOMATCH);
1697 0 0 if (eptr < md->start_used_ptr) md->start_used_ptr = eptr;
1706 0 0 if (PUBL(callout) != NULL)
1727 0 0 if (cb.capture_last == 0) cb.capture_last = -1;
1730 0 0 if ((rrc = (*PUBL(callout))(&cb)) > 0) RRETURN(MATCH_NOMATCH);
1731 0 0 if (rrc < 0) RRETURN(rrc);
1759 0 0 recno = (callpat == md->start_code)? 0 :
1766 0 0 for (ri = md->recursive; ri != NULL; ri = ri->prevrec)
1767 0 0 if (recno == ri->group_num && eptr == ri->subject_position)
0 0 if (recno == ri->group_num && eptr == ri->subject_position)
1785 0 0 if (new_recursive.saved_max <= REC_STACK_SAVE_MAX)
1791 0 0 if (new_recursive.offset_save == NULL) RRETURN(PCRE_ERROR_NOMEMORY);
1805 0 0 if (cbegroup) md->match_function_type = MATCH_CBEGROUP;
1812 0 0 if (rrc == MATCH_MATCH || rrc == MATCH_ACCEPT)
0 0 if (rrc == MATCH_MATCH || rrc == MATCH_ACCEPT)
1815 0 0 if (new_recursive.offset_save != stacksave)
1831 0 0 if (rrc >= MATCH_BACKTRACK_MIN && rrc <= MATCH_BACKTRACK_MAX)
0 0 if (rrc >= MATCH_BACKTRACK_MIN && rrc <= MATCH_BACKTRACK_MAX)
1833 0 0 if (new_recursive.offset_save != stacksave)
1840 0 0 if (rrc != MATCH_NOMATCH)
1843 0 0 if (new_recursive.offset_save != stacksave)
1851 0 0 while (*callpat == OP_ALT);
1855 0 0 if (new_recursive.offset_save != stacksave)
1867 0 0 do ecode += GET(ecode,1); while (*ecode == OP_ALT);
1879 3 7 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1880 0 7 do next += GET(next, 1); while (*next == OP_ALT);
1886 0 0 do next += GET(next, 1); while (*next == OP_ALT);
1888 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
1894 0 0 do next += GET(next,1); while (*next == OP_ALT);
1904 0 0 if (op == OP_CBRAPOS || op == OP_SCBRAPOS) goto POSSESSIVE_CAPTURE;
0 0 if (op == OP_CBRAPOS || op == OP_SCBRAPOS) goto POSSESSIVE_CAPTURE;
1919 17 0 if (*prev >= OP_SBRA || *prev == OP_ONCE)
0 17 if (*prev >= OP_SBRA || *prev == OP_ONCE)
1931 17 0 if ((*prev >= OP_ASSERT && *prev <= OP_ASSERTBACK_NOT) ||
17 0 if ((*prev >= OP_ASSERT && *prev <= OP_ASSERTBACK_NOT) ||
0 17 if ((*prev >= OP_ASSERT && *prev <= OP_ASSERTBACK_NOT) ||
1948 14 3 if (*prev == OP_CBRA || *prev == OP_SCBRA ||
14 0 if (*prev == OP_CBRA || *prev == OP_SCBRA ||
14 0 if (*prev == OP_CBRA || *prev == OP_SCBRA ||
1949 0 14 *prev == OP_CBRAPOS || *prev == OP_SCBRAPOS)
1961 0 3 if (md->recursive != NULL && md->recursive->group_num == number)
0 0 if (md->recursive != NULL && md->recursive->group_num == number)
1971 3 0 if (offset >= md->offset_max) md->capture_last |= OVFLBIT; else
1983 0 0 if (offset > offset_top)
1987 0 0 while (iptr < iend) *iptr++ = -1;
1995 0 0 if (offset_top <= offset) offset_top = offset + 2;
2004 0 17 if (*ecode == OP_KETRPOS)
2021 0 17 if (*ecode == OP_KET || eptr == saved_eptr)
0 0 if (*ecode == OP_KET || eptr == saved_eptr)
2023 0 17 if (*prev == OP_ONCE)
2026 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2040 0 0 if (*ecode == OP_KETRMIN)
2043 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2044 0 0 if (*prev == OP_ONCE)
2047 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2051 0 0 if (*prev >= OP_SBRA) /* Could match an empty string */
2062 0 0 if (rrc == MATCH_ONCE && md->once_target == prev) rrc = MATCH_NOMATCH;
0 0 if (rrc == MATCH_ONCE && md->once_target == prev) rrc = MATCH_NOMATCH;
2063 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2064 0 0 if (*prev == OP_ONCE)
2067 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2079 0 29 if (md->notbol && eptr == md->start_subject) RRETURN(MATCH_NOMATCH);
0 0 if (md->notbol && eptr == md->start_subject) RRETURN(MATCH_NOMATCH);
2084 0 29 if (eptr != md->start_subject) RRETURN(MATCH_NOMATCH);
2091 0 0 if (md->notbol && eptr == md->start_subject) RRETURN(MATCH_NOMATCH);
0 0 if (md->notbol && eptr == md->start_subject) RRETURN(MATCH_NOMATCH);
2092 0 0 if (eptr != md->start_subject &&
0 0 if (eptr != md->start_subject &&
0 0 if (eptr != md->start_subject &&
2093 0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
0 0 (eptr == md->end_subject || !WAS_NEWLINE(eptr)))
2101 0 0 if (eptr != md->start_subject + md->start_offset) RRETURN(MATCH_NOMATCH);
2116 0 0 if (eptr < md->end_subject)
2118 0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
0 0 if (!IS_NEWLINE(eptr))
2120 0 0 if (md->partial != 0 &&
0 0 if (md->partial != 0 &&
2121 0 0 eptr + 1 >= md->end_subject &&
2122 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
2123 0 0 NLBLOCK->nllen == 2 &&
2127 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
2134 0 0 if (md->noteol) RRETURN(MATCH_NOMATCH);
2135 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2144 0 11 if (md->noteol) RRETURN(MATCH_NOMATCH);
2145 11 0 if (!md->endonly) goto ASSERT_NL_OR_EOS;
2152 0 0 if (eptr < md->end_subject) RRETURN(MATCH_NOMATCH);
2153 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2161 1 10 if (eptr < md->end_subject &&
1 0 if (eptr < md->end_subject &&
0 1 if (eptr < md->end_subject &&
2162 1 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
1 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
0 0 (!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
2164 0 1 if (md->partial != 0 &&
0 0 if (md->partial != 0 &&
2165 0 0 eptr + 1 >= md->end_subject &&
2166 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
2167 0 0 NLBLOCK->nllen == 2 &&
2171 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
2178 0 10 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2251 0 0 if (eptr == md->start_subject) prev_is_word = FALSE; else
2253 0 0 if (eptr <= md->start_used_ptr) md->start_used_ptr = eptr - 1;
2272 0 0 if (eptr >= md->end_subject)
2274 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2296 0 0 if ((*ecode++ == OP_WORD_BOUNDARY)?
0 0 if ((*ecode++ == OP_WORD_BOUNDARY)?
2306 0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
2307 0 0 if (md->partial != 0 &&
0 0 if (md->partial != 0 &&
2308 0 0 eptr == md->end_subject - 1 &&
2309 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
2310 0 0 NLBLOCK->nllen == 2 &&
2314 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
2322 0 0 if (eptr >= md->end_subject) /* DO NOT merge the eptr++ here; it must */
2324 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2338 0 0 if (eptr >= md->end_subject) /* DO NOT merge the eptr++ here; it must */
2340 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2348 0 0 if (eptr >= md->end_subject)
2350 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2354 0 0 if (
2365 0 0 if (eptr >= md->end_subject)
2367 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2371 0 0 if (
2382 0 0 if (eptr >= md->end_subject)
2384 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2388 0 0 if (
2399 0 0 if (eptr >= md->end_subject)
2401 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2405 0 0 if (
2416 0 0 if (eptr >= md->end_subject)
2418 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2422 0 0 if (
2433 0 0 if (eptr >= md->end_subject)
2435 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2439 0 0 if (
2450 0 0 if (eptr >= md->end_subject)
2452 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2461 0 0 if (eptr >= md->end_subject)
2463 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2465 0 0 else if (UCHAR21TEST(eptr) == CHAR_LF) eptr++;
2478 0 0 if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
2485 0 0 if (eptr >= md->end_subject)
2487 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2491 0 0 switch(c)
2500 0 0 if (eptr >= md->end_subject)
2502 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2506 0 0 switch(c)
2515 0 0 if (eptr >= md->end_subject)
2517 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2521 0 0 switch(c)
2530 0 0 if (eptr >= md->end_subject)
2532 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2536 0 0 switch(c)
2715 0 0 length = (md->jscript_compat)? 0 : -1;
2718 0 0 while (count-- > 0)
2721 0 0 if (offset < offset_top && md->offset_vector[offset] >= 0)
0 0 if (offset < offset_top && md->offset_vector[offset] >= 0)
2736 0 0 if (offset >= offset_top || md->offset_vector[offset] < 0)
0 0 if (offset >= offset_top || md->offset_vector[offset] < 0)
2737 0 0 length = (md->jscript_compat)? 0 : -1;
2756 0 0 if (max == 0) max = INT_MAX;
2764 0 0 if (max == 0) max = INT_MAX;
2769 0 0 if ((length = match_ref(offset, eptr, length, md, caseless)) < 0)
2771 0 0 if (length == -2) eptr = md->end_subject; /* Partial match */
2772 0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
2785 0 0 if (length == 0) continue;
2786 0 0 if (length < 0 && min == 0) continue;
0 0 if (length < 0 && min == 0) continue;
2792 0 0 for (i = 1; i <= min; i++)
2795 0 0 if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
2797 0 0 if (slength == -2) eptr = md->end_subject; /* Partial match */
2798 0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
2807 0 0 if (min == max) continue;
2811 0 0 if (minimize)
2817 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2818 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
2819 0 0 if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
2821 0 0 if (slength == -2) eptr = md->end_subject; /* Partial match */
2822 0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
0 0 CHECK_PARTIAL();
2835 0 0 for (i = min; i < max; i++)
2838 0 0 if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
2843 0 0 if (slength == -2 && md->partial != 0 &&
0 0 if (slength == -2 && md->partial != 0 &&
0 0 if (slength == -2 && md->partial != 0 &&
2847 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
2854 0 0 while (eptr >= pp)
2857 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
2896 0 0 if (c < OP_CRPOSSTAR - OP_CRSTAR) minimize = (c & 1) != 0;
2900 0 0 if (max == 0) max = INT_MAX;
2910 0 0 if (max == 0) max = INT_MAX;
2944 0 0 for (i = 1; i <= min; i++)
2946 0 0 if (eptr >= md->end_subject)
2948 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
2959 0 0 if ((BYTE_MAP[c/8] & (1 << (c&7))) == 0) RRETURN(MATCH_NOMATCH);
2966 0 0 if (min == max) continue;
2971 0 0 if (minimize)
3002 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3003 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
3004 0 0 if (eptr >= md->end_subject)
3006 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3017 0 0 if ((BYTE_MAP[c/8] & (1 << (c&7))) == 0) RRETURN(MATCH_NOMATCH);
3064 0 0 for (i = min; i < max; i++)
3066 0 0 if (eptr >= md->end_subject)
3068 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3079 0 0 if ((BYTE_MAP[c/8] & (1 << (c&7))) == 0) break;
3083 0 0 if (possessive) continue; /* No backtracking */
3085 0 0 while (eptr >= pp)
3088 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3245 10 411 if (md->end_subject - eptr < 1)
3247 0 10 SCHECK_PARTIAL(); /* This one can use SCHECK_PARTIAL() */
0 0 SCHECK_PARTIAL(); /* This one can use SCHECK_PARTIAL() */
0 0 SCHECK_PARTIAL(); /* This one can use SCHECK_PARTIAL() */
3250 115 296 if (ecode[1] != *eptr++) RRETURN(MATCH_NOMATCH);
3259 0 0 if (eptr >= md->end_subject)
3261 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3312 0 0 if (TABLE_GET(ecode[1], md->lcc, ecode[1])
3338 0 0 minimize = *ecode == OP_MINUPTO || *ecode == OP_MINUPTOI;
0 0 minimize = *ecode == OP_MINUPTO || *ecode == OP_MINUPTOI;
3378 0 0 c = *ecode++ - ((op < OP_STARI)? OP_STAR : OP_STARI);
3382 0 0 if (max == 0) max = INT_MAX;
3521 0 0 if (op >= OP_STARI) /* Caseless */
3540 0 0 for (i = 1; i <= min; i++)
3543 0 0 if (eptr >= md->end_subject)
3545 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3549 0 0 if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
0 0 if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
3552 0 0 if (min == max) continue;
3553 0 0 if (minimize)
3559 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3560 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
3561 0 0 if (eptr >= md->end_subject)
3563 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3567 0 0 if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
0 0 if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
3575 0 0 for (i = min; i < max; i++)
3578 0 0 if (eptr >= md->end_subject)
3580 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3584 0 0 if (fc != cc && foc != cc) break;
0 0 if (fc != cc && foc != cc) break;
3587 0 0 if (possessive) continue; /* No backtracking */
3590 0 0 if (eptr == pp) goto TAIL_RECURSE;
3593 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3603 0 0 for (i = 1; i <= min; i++)
3605 0 0 if (eptr >= md->end_subject)
3607 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3610 0 0 if (fc != UCHAR21INCTEST(eptr)) RRETURN(MATCH_NOMATCH);
3613 0 0 if (min == max) continue;
3615 0 0 if (minimize)
3620 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3621 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
3622 0 0 if (eptr >= md->end_subject)
3624 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3627 0 0 if (fc != UCHAR21INCTEST(eptr)) RRETURN(MATCH_NOMATCH);
3634 0 0 for (i = min; i < max; i++)
3636 0 0 if (eptr >= md->end_subject)
3638 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3641 0 0 if (fc != UCHAR21TEST(eptr)) break;
3644 0 0 if (possessive) continue; /* No backtracking */
3647 0 0 if (eptr == pp) goto TAIL_RECURSE;
3650 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3662 0 0 if (eptr >= md->end_subject)
3664 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3699 0 0 if (ch == c || (op == OP_NOTI && TABLE_GET(ch, md->fcc, ch) == c))
0 0 if (ch == c || (op == OP_NOTI && TABLE_GET(ch, md->fcc, ch) == c))
0 0 if (ch == c || (op == OP_NOTI && TABLE_GET(ch, md->fcc, ch) == c))
3724 0 0 minimize = *ecode == OP_NOTMINUPTO || *ecode == OP_NOTMINUPTOI;
0 0 minimize = *ecode == OP_NOTMINUPTO || *ecode == OP_NOTMINUPTOI;
3772 0 0 c = *ecode++ - ((op >= OP_NOTSTARI)? OP_NOTSTARI: OP_NOTSTAR);
3776 0 0 if (max == 0) max = INT_MAX;
3794 0 0 if (op >= OP_NOTSTARI) /* Caseless */
3827 0 0 for (i = 1; i <= min; i++)
3829 0 0 if (eptr >= md->end_subject)
3831 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3834 0 0 if (fc == *eptr || foc == *eptr) RRETURN(MATCH_NOMATCH);
0 0 if (fc == *eptr || foc == *eptr) RRETURN(MATCH_NOMATCH);
3839 0 0 if (min == max) continue;
3841 0 0 if (minimize)
3868 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3869 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
3870 0 0 if (eptr >= md->end_subject)
3872 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3875 0 0 if (fc == *eptr || foc == *eptr) RRETURN(MATCH_NOMATCH);
0 0 if (fc == *eptr || foc == *eptr) RRETURN(MATCH_NOMATCH);
3918 0 0 for (i = min; i < max; i++)
3920 0 0 if (eptr >= md->end_subject)
3922 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3925 0 0 if (fc == *eptr || foc == *eptr) break;
0 0 if (fc == *eptr || foc == *eptr) break;
3928 0 0 if (possessive) continue; /* No backtracking */
3931 0 0 if (eptr == pp) goto TAIL_RECURSE;
3933 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
3964 0 0 for (i = 1; i <= min; i++)
3966 0 0 if (eptr >= md->end_subject)
3968 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
3971 0 0 if (fc == *eptr++) RRETURN(MATCH_NOMATCH);
3975 0 0 if (min == max) continue;
3977 0 0 if (minimize)
4004 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
4005 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
4006 0 0 if (eptr >= md->end_subject)
4008 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4011 0 0 if (fc == *eptr++) RRETURN(MATCH_NOMATCH);
4053 0 0 for (i = min; i < max; i++)
4055 0 0 if (eptr >= md->end_subject)
4057 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4060 0 0 if (fc == *eptr) break;
4063 0 0 if (possessive) continue; /* No backtracking */
4066 0 0 if (eptr == pp) goto TAIL_RECURSE;
4068 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
4133 10 0 if (max == 0) max = INT_MAX;
4158 4 10 if (min > 0)
4637 4 4 for (i = 1; i <= min; i++)
4639 0 4 if (eptr >= md->end_subject)
4641 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4644 4 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
4 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 4 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 0 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
0 4 if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
4645 0 4 if (md->partial != 0 &&
0 0 if (md->partial != 0 &&
4646 0 0 eptr + 1 >= md->end_subject &&
4647 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
4648 0 0 NLBLOCK->nllen == 2 &&
4652 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
4659 0 0 if (eptr > md->end_subject - min)
4661 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4668 0 0 if (eptr > md->end_subject - min)
4670 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4677 0 0 for (i = 1; i <= min; i++)
4679 0 0 if (eptr >= md->end_subject)
4681 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4689 0 0 if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
0 0 if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
4702 0 0 if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
4709 0 0 for (i = 1; i <= min; i++)
4711 0 0 if (eptr >= md->end_subject)
4713 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4716 0 0 switch(*eptr++)
4729 0 0 for (i = 1; i <= min; i++)
4731 0 0 if (eptr >= md->end_subject)
4733 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4736 0 0 switch(*eptr++)
4749 0 0 for (i = 1; i <= min; i++)
4751 0 0 if (eptr >= md->end_subject)
4753 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4756 0 0 switch(*eptr++)
4769 0 0 for (i = 1; i <= min; i++)
4771 0 0 if (eptr >= md->end_subject)
4773 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4776 0 0 switch(*eptr++)
4789 0 0 for (i = 1; i <= min; i++)
4791 0 0 if (eptr >= md->end_subject)
4793 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4796 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_digit) != 0)
4803 0 0 for (i = 1; i <= min; i++)
4805 0 0 if (eptr >= md->end_subject)
4807 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4810 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_digit) == 0)
4817 0 0 for (i = 1; i <= min; i++)
4819 0 0 if (eptr >= md->end_subject)
4821 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4824 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_space) != 0)
4831 0 0 for (i = 1; i <= min; i++)
4833 0 0 if (eptr >= md->end_subject)
4835 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4838 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_space) == 0)
4845 0 0 for (i = 1; i <= min; i++)
4847 0 0 if (eptr >= md->end_subject)
4849 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4852 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_word) != 0)
4859 0 0 for (i = 1; i <= min; i++)
4861 0 0 if (eptr >= md->end_subject)
4863 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
4866 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_word) == 0)
4879 0 14 if (min == max) continue;
4885 0 14 if (minimize)
5269 0 0 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
5270 0 0 if (fi >= max) RRETURN(MATCH_NOMATCH);
5271 0 0 if (eptr >= md->end_subject)
5273 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
5276 0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
0 0 if (ctype == OP_ANY && IS_NEWLINE(eptr))
5282 0 0 if (md->partial != 0 && /* Take care with CRLF partial */
0 0 if (md->partial != 0 && /* Take care with CRLF partial */
5283 0 0 eptr >= md->end_subject &&
5284 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
5285 0 0 NLBLOCK->nllen == 2 &&
5289 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
5302 0 0 if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
0 0 if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
5315 0 0 if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
5321 0 0 switch(c)
5333 0 0 switch(c)
5345 0 0 switch(c)
5357 0 0 switch(c)
5369 0 0 if (MAX_255(c) && (md->ctypes[c] & ctype_digit) != 0) RRETURN(MATCH_NOMATCH);
5373 0 0 if (!MAX_255(c) || (md->ctypes[c] & ctype_digit) == 0) RRETURN(MATCH_NOMATCH);
5377 0 0 if (MAX_255(c) && (md->ctypes[c] & ctype_space) != 0) RRETURN(MATCH_NOMATCH);
5381 0 0 if (!MAX_255(c) || (md->ctypes[c] & ctype_space) == 0) RRETURN(MATCH_NOMATCH);
5385 0 0 if (MAX_255(c) && (md->ctypes[c] & ctype_word) != 0) RRETURN(MATCH_NOMATCH);
5389 0 0 if (!MAX_255(c) || (md->ctypes[c] & ctype_word) == 0) RRETURN(MATCH_NOMATCH);
5949 155 0 for (i = min; i < max; i++)
5951 14 141 if (eptr >= md->end_subject)
5953 0 14 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
5956 141 0 if (IS_NEWLINE(eptr)) break;
141 0 if (IS_NEWLINE(eptr)) break;
0 141 if (IS_NEWLINE(eptr)) break;
0 0 if (IS_NEWLINE(eptr)) break;
0 0 if (IS_NEWLINE(eptr)) break;
0 0 if (IS_NEWLINE(eptr)) break;
0 0 if (IS_NEWLINE(eptr)) break;
0 141 if (IS_NEWLINE(eptr)) break;
5957 0 141 if (md->partial != 0 && /* Take care with CRLF partial */
0 0 if (md->partial != 0 && /* Take care with CRLF partial */
5958 0 0 eptr + 1 >= md->end_subject &&
5959 0 0 NLBLOCK->nltype == NLTYPE_FIXED &&
5960 0 0 NLBLOCK->nllen == 2 &&
5964 0 0 if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
5973 0 0 if (c > (unsigned int)(md->end_subject - eptr))
5976 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
5982 0 0 for (i = min; i < max; i++)
5984 0 0 if (eptr >= md->end_subject)
5986 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
5990 0 0 if (c == CHAR_CR)
5992 0 0 if (++eptr >= md->end_subject) break;
5993 0 0 if (*eptr == CHAR_LF) eptr++;
5997 0 0 if (c != CHAR_LF && (md->bsr_anycrlf ||
0 0 if (c != CHAR_LF && (md->bsr_anycrlf ||
0 0 if (c != CHAR_LF && (md->bsr_anycrlf ||
5998 0 0 (c != CHAR_VT && c != CHAR_FF && c != CHAR_NEL
0 0 (c != CHAR_VT && c != CHAR_FF && c != CHAR_NEL
6009 0 0 for (i = min; i < max; i++)
6011 0 0 if (eptr >= md->end_subject)
6013 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6016 0 0 switch(*eptr)
6030 0 0 for (i = min; i < max; i++)
6032 0 0 if (eptr >= md->end_subject)
6034 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6037 0 0 switch(*eptr)
6051 0 0 for (i = min; i < max; i++)
6053 0 0 if (eptr >= md->end_subject)
6055 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6058 0 0 switch(*eptr)
6072 0 0 for (i = min; i < max; i++)
6074 0 0 if (eptr >= md->end_subject)
6076 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6079 0 0 switch(*eptr)
6093 0 0 for (i = min; i < max; i++)
6095 0 0 if (eptr >= md->end_subject)
6097 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6100 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_digit) != 0) break;
6106 0 0 for (i = min; i < max; i++)
6108 0 0 if (eptr >= md->end_subject)
6110 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6113 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_digit) == 0) break;
6119 0 0 for (i = min; i < max; i++)
6121 0 0 if (eptr >= md->end_subject)
6123 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6126 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_space) != 0) break;
6132 0 0 for (i = min; i < max; i++)
6134 0 0 if (eptr >= md->end_subject)
6136 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6139 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_space) == 0) break;
6145 0 0 for (i = min; i < max; i++)
6147 0 0 if (eptr >= md->end_subject)
6149 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6152 0 0 if (MAX_255(*eptr) && (md->ctypes[*eptr] & ctype_word) != 0) break;
6158 0 0 for (i = min; i < max; i++)
6160 0 0 if (eptr >= md->end_subject)
6162 0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
0 0 SCHECK_PARTIAL();
6165 0 0 if (!MAX_255(*eptr) || (md->ctypes[*eptr] & ctype_word) == 0) break;
6174 4 10 if (possessive) continue; /* No backtracking */
6177 0 62 if (eptr == pp) goto TAIL_RECURSE;
6179 10 52 if (rrc != MATCH_NOMATCH) RRETURN(rrc);
6181 0 52 if (ctype == OP_ANYNL && eptr > pp && *eptr == CHAR_LF &&
0 0 if (ctype == OP_ANYNL && eptr > pp && *eptr == CHAR_LF &&
0 0 if (ctype == OP_ANYNL && eptr > pp && *eptr == CHAR_LF &&
0 0 if (ctype == OP_ANYNL && eptr > pp && *eptr == CHAR_LF &&
6400 0 454 if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
0 0 if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
0 0 if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
0 0 if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
0 0 if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
6410 0 454 if ((options & ~PUBLIC_EXEC_OPTIONS) != 0) return PCRE_ERROR_BADOPTION;
6411 454 0 if (re == NULL || subject == NULL || (offsets == NULL && offsetcount > 0))
454 0 if (re == NULL || subject == NULL || (offsets == NULL && offsetcount > 0))
454 0 if (re == NULL || subject == NULL || (offsets == NULL && offsetcount > 0))
0 454 if (re == NULL || subject == NULL || (offsets == NULL && offsetcount > 0))
6413 0 454 if (offsetcount < 0) return PCRE_ERROR_BADCOUNT;
6414 0 454 if (length < 0) return PCRE_ERROR_BADLENGTH;
6415 454 0 if (start_offset < 0 || start_offset > length) return PCRE_ERROR_BADOFFSET;
0 454 if (start_offset < 0 || start_offset > length) return PCRE_ERROR_BADOFFSET;
6422 0 454 if (re->magic_number != MAGIC_NUMBER)
6424 0 0 PCRE_ERROR_BADENDIANNESS:PCRE_ERROR_BADMAGIC;
6425 0 454 if ((re->flags & PCRE_MODE) == 0) return PCRE_ERROR_BADMODE;
6434 454 0 md->partial = ((options & PCRE_PARTIAL_HARD) != 0)? 2 :
6514 0 454 if (extra_data != NULL)
6517 0 0 if ((flags & PCRE_EXTRA_STUDY_DATA) != 0)
6519 0 0 if ((flags & PCRE_EXTRA_MATCH_LIMIT) != 0)
6521 0 0 if ((flags & PCRE_EXTRA_MATCH_LIMIT_RECURSION) != 0)
6523 0 0 if ((flags & PCRE_EXTRA_CALLOUT_DATA) != 0)
6525 0 0 if ((flags & PCRE_EXTRA_TABLES) != 0) tables = extra_data->tables;
6530 0 454 if ((re->flags & PCRE_MLSET) != 0 && re->limit_match < md->match_limit)
0 0 if ((re->flags & PCRE_MLSET) != 0 && re->limit_match < md->match_limit)
6533 0 454 if ((re->flags & PCRE_RLSET) != 0 &&
0 0 if ((re->flags & PCRE_RLSET) != 0 &&
6541 454 0 if (tables == NULL) tables = PRIV(default_tables);
6587 0 454 if ((re->options & (PCRE_BSR_ANYCRLF|PCRE_BSR_UNICODE)) != 0)
6612 454 0 (pcre_uint32)options) & PCRE_NEWLINE_BITS)
6624 454 0 if (newline == -2)
6628 0 0 else if (newline < 0)
6635 0 0 if (newline > 255)
6652 0 454 if (md->partial && (re->flags & PCRE_NOPARTIAL) != 0)
0 0 if (md->partial && (re->flags & PCRE_NOPARTIAL) != 0)
6663 0 454 if (re->top_backref > 0 && re->top_backref >= ocount/3)
0 0 if (re->top_backref > 0 && re->top_backref >= ocount/3)
6667 0 0 if (md->offset_vector == NULL) return PCRE_ERROR_NOMEMORY;
6682 0 454 if (md->offset_vector != NULL)
6686 0 0 if (iend < md->offset_vector + 2) iend = md->offset_vector + 2;
6687 0 0 while (--iptr >= iend) *iptr = -1;
6688 0 0 if (offsetcount > 0) md->offset_vector[0] = -1;
6689 0 0 if (offsetcount > 1) md->offset_vector[1] = -1;
6698 400 54 if (!anchored)
6700 400 0 if ((re->flags & PCRE_FIRSTSET) != 0)
6704 0 400 if ((re->flags & PCRE_FCH_CASELESS) != 0)
6714 0 0 if (!startline && study != NULL &&
0 0 if (!startline && study != NULL &&
0 0 if (!startline && study != NULL &&
6722 453 1 if ((re->flags & PCRE_REQCHSET) != 0)
6726 0 453 if ((re->flags & PCRE_RCH_CASELESS) != 0)
6753 0 502 if (firstline)
6767 0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
0 0 while (t < md->end_subject && !IS_NEWLINE(t)) t++;
6777 502 0 if (((options | re->options) & PCRE_NO_START_OPTIMIZE) == 0)
6781 448 54 if (has_first_char)
6785 0 448 if (first_char != first_char2)
6786 0 0 while (start_match < end_subject &&
0 0 while (start_match < end_subject &&
6787 0 0 (smc = UCHAR21TEST(start_match)) != first_char && smc != first_char2)
6790 4879 224 while (start_match < end_subject && UCHAR21TEST(start_match) != first_char)
4655 224 while (start_match < end_subject && UCHAR21TEST(start_match) != first_char)
6796 0 54 else if (startline)
6798 0 0 if (start_match > md->start_subject + start_offset)
6812 0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
0 0 while (start_match < end_subject && !WAS_NEWLINE(start_match))
6819 0 0 if (start_match[-1] == CHAR_CR &&
0 0 if (start_match[-1] == CHAR_CR &&
6820 0 0 (md->nltype == NLTYPE_ANY || md->nltype == NLTYPE_ANYCRLF) &&
0 0 (md->nltype == NLTYPE_ANY || md->nltype == NLTYPE_ANYCRLF) &&
6821 0 0 start_match < end_subject &&
6829 0 54 else if (start_bits != NULL)
6831 0 0 while (start_match < end_subject)
6837 0 0 if ((start_bits[c/8] & (1 << (c&7))) != 0) break;
6850 502 0 if (((options | re->options) & PCRE_NO_START_OPTIMIZE) == 0 && !md->partial)
502 0 if (((options | re->options) & PCRE_NO_START_OPTIMIZE) == 0 && !md->partial)
6857 0 502 if (study != NULL && (study->flags & PCRE_STUDY_MINLEN) != 0 &&
0 0 if (study != NULL && (study->flags & PCRE_STUDY_MINLEN) != 0 &&
0 0 if (study != NULL && (study->flags & PCRE_STUDY_MINLEN) != 0 &&
6878 501 1 if (has_req_char && end_subject - start_match < REQ_BYTE_MAX)
501 0 if (has_req_char && end_subject - start_match < REQ_BYTE_MAX)
6880 448 53 register PCRE_PUCHAR p = start_match + (has_first_char? 1:0);
6885 501 0 if (p > req_char_ptr)
6887 0 501 if (req_char != req_char2)
6889 0 0 while (p < end_subject)
6892 0 0 if (pp == req_char || pp == req_char2) { p--; break; }
0 0 if (pp == req_char || pp == req_char2) { p--; break; }
6897 1950 421 while (p < end_subject)
6899 80 1870 if (UCHAR21INCTEST(p) == req_char) { p--; break; }
6906 421 80 if (p >= end_subject)
6937 0 81 if (md->hitend && start_partial == NULL)
0 0 if (md->hitend && start_partial == NULL)
6961 0 0 if (md->start_match_ptr > start_match)
7004 0 67 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
0 0 if (firstline && IS_NEWLINE(start_match)) break;
7013 48 19 if (anchored || start_match > end_subject) break;
48 0 if (anchored || start_match > end_subject) break;
7022 48 0 if (start_match > (PCRE_PUCHAR)subject + start_offset &&
0 48 if (start_match > (PCRE_PUCHAR)subject + start_offset &&
7023 0 0 start_match[-1] == CHAR_CR &&
7024 0 0 start_match < end_subject &&
7025 0 0 *start_match == CHAR_NL &&
7026 0 0 (re->flags & PCRE_HASCRORLF) == 0 &&
7027 0 0 (md->nltype == NLTYPE_ANY ||
7028 0 0 md->nltype == NLTYPE_ANYCRLF ||
7057 440 14 if (rc == MATCH_MATCH || rc == MATCH_ACCEPT)
0 440 if (rc == MATCH_MATCH || rc == MATCH_ACCEPT)
7059 0 14 if (using_temporary_offsets)
7061 0 0 if (arg_offset_max >= 4)
7067 0 0 if (md->end_offset_top > arg_offset_max) md->capture_last |= OVFLBIT;
7075 0 3 rc = ((md->capture_last & OVFLBIT) != 0 &&
7077 3 11 0 : md->end_offset_top/2;
7088 10 4 if (md->end_offset_top/2 <= re->top_bracket && offsets != NULL)
0 10 if (md->end_offset_top/2 <= re->top_bracket && offsets != NULL)
7092 0 0 if (resetcount > offsetcount) resetcount = offsetcount;
7095 0 0 while (iptr < iend) *iptr++ = -1;
7102 14 0 if (offsetcount < 2) rc = 0; else
7110 0 14 if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)
0 0 if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)
7122 0 440 if (using_temporary_offsets)
7130 0 440 if (rc != MATCH_NOMATCH && rc != PCRE_ERROR_PARTIAL)
0 0 if (rc != MATCH_NOMATCH && rc != PCRE_ERROR_PARTIAL)
7141 0 440 if (match_partial != NULL)
7145 0 0 if (offsetcount > 1)
7149 0 0 if (offsetcount > 2)
7165 0 440 if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)
0 0 if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)