Skip to content

Fix panic in Unicode wildcard matching #17753

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 29, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions regcomp.c
Original file line number Diff line number Diff line change
Expand Up @@ -13565,8 +13565,8 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
/* SBOL is shared with /^/ so we set the flags so we can tell
* /\A/ from /^/ in split. */
FLAGS(REGNODE_p(ret)) = 1;
*flagp |= SIMPLE; /* Wrong, but too late to fix for 5.32 */
}
*flagp |= SIMPLE;
goto finish_meta_pat;
case 'G':
if (RExC_pm_flags & PMf_WILDCARD) {
Expand Down Expand Up @@ -13604,8 +13604,8 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
}
else {
ret = reg_node(pRExC_state, SEOL);
*flagp |= SIMPLE; /* Wrong, but too late to fix for 5.32 */
}
*flagp |= SIMPLE;
RExC_seen_zerolen++; /* Do not optimize RE away */
goto finish_meta_pat;
case 'z':
Expand All @@ -13615,8 +13615,8 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
}
else {
ret = reg_node(pRExC_state, EOS);
*flagp |= SIMPLE; /* Wrong, but too late to fix for 5.32 */
}
*flagp |= SIMPLE;
RExC_seen_zerolen++; /* Do not optimize RE away */
goto finish_meta_pat;
case 'C':
Expand Down