Tidy some confusing code.

This commit is contained in:
Philip.Hazel 2017-04-12 13:26:11 +00:00
parent 3b8672bf49
commit b3154eb907
1 changed files with 67 additions and 65 deletions

View File

@ -6713,23 +6713,25 @@ else for (gmatched = 0;; gmatched++)
} }
/* Find the heap, match and depth limits if requested. The match and heap /* Find the heap, match and depth limits if requested. The match and heap
limits are not relevant for DFA matching and the depth limit is not relevant limits are not relevant for DFA matching and the depth and heap limits are
for JIT. */ not relevant for JIT. The return from check_match_limit() is the return from
the final call to pcre2_match() or pcre2_dfa_match(). */
if ((dat_datctl.control & CTL_FINDLIMITS) != 0) if ((dat_datctl.control & CTL_FINDLIMITS) != 0)
{ {
capcount = 0; /* This stops compiler warnings */
if ((dat_datctl.control & CTL_DFA) == 0) if ((dat_datctl.control & CTL_DFA) == 0)
{ {
if (FLD(compiled_code, executable_jit) == NULL || if (FLD(compiled_code, executable_jit) == NULL ||
(dat_datctl.options & PCRE2_NO_JIT) != 0) (dat_datctl.options & PCRE2_NO_JIT) != 0)
{ {
capcount = check_match_limit(pp, arg_ulen, PCRE2_ERROR_HEAPLIMIT, (void)check_match_limit(pp, arg_ulen, PCRE2_ERROR_HEAPLIMIT,
"heap"); "heap");
} }
capcount = check_match_limit(pp, arg_ulen, PCRE2_ERROR_MATCHLIMIT, capcount = check_match_limit(pp, arg_ulen, PCRE2_ERROR_MATCHLIMIT,
"match"); "match");
} }
else capcount = 0;
if (FLD(compiled_code, executable_jit) == NULL || if (FLD(compiled_code, executable_jit) == NULL ||
(dat_datctl.options & PCRE2_NO_JIT) != 0 || (dat_datctl.options & PCRE2_NO_JIT) != 0 ||