summaryrefslogtreecommitdiff
path: root/regexec.c
diff options
context:
space:
mode:
Diffstat (limited to 'regexec.c')
-rw-r--r--regexec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/regexec.c b/regexec.c
index c1f1ae26ea..f2723e4cc6 100644
--- a/regexec.c
+++ b/regexec.c
@@ -6356,8 +6356,8 @@ S_reginclass(pTHX_ const regexp * const prog, register const regnode * const n,
match = TRUE;
}
- if (!match && (flags & ANYOF_CLASS) && ANYOF_CLASS_TEST_ANY_SET(n)) {
- PL_reg_flags |= RF_tainted;
+ if (!match && ANYOF_CLASS_TEST_ANY_SET(n)) {
+ PL_reg_flags |= RF_tainted; /* CLASS implies LOCALE */
if (
(ANYOF_CLASS_TEST(n, ANYOF_ALNUM) && isALNUM_LC(c)) ||
(ANYOF_CLASS_TEST(n, ANYOF_NALNUM) && !isALNUM_LC(c)) ||