summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pcre_compile.c7
-rw-r--r--pcre_exec.c3
2 files changed, 4 insertions, 6 deletions
diff --git a/pcre_compile.c b/pcre_compile.c
index e8bb9cc..ddb8d16 100644
--- a/pcre_compile.c
+++ b/pcre_compile.c
@@ -5932,11 +5932,10 @@ for (;; ptr++)
cd->assert_depth -= 1;
/* At the end of compiling, code is still pointing to the start of the
- group, while tempcode has been updated to point past the end of the group
- and any option resetting that may follow it. The pattern pointer (ptr)
- is on the bracket. */
+ group, while tempcode has been updated to point past the end of the group.
+ The pattern pointer (ptr) is on the bracket.
- /* If this is a conditional bracket, check that there are no more than
+ If this is a conditional bracket, check that there are no more than
two branches in the group, or just one if it's a DEFINE group. We do this
in the real compile phase, not in the pre-pass, where the whole group may
not be available. */
diff --git a/pcre_exec.c b/pcre_exec.c
index 8ee01dc..6c6c260 100644
--- a/pcre_exec.c
+++ b/pcre_exec.c
@@ -1750,8 +1750,7 @@ for (;;)
assertions. We also need to record the match start in case it was changed
by \K. */
- if (*prev == OP_ASSERT || *prev == OP_ASSERT_NOT ||
- *prev == OP_ASSERTBACK || *prev == OP_ASSERTBACK_NOT)
+ if (*prev >= OP_ASSERT && *prev <= OP_ASSERTBACK_NOT)
{
md->end_match_ptr = eptr; /* For ONCE */
md->end_offset_top = offset_top;