From b1e3e569b09fd7f24fa3e311cdf8e3d3d8ca931a Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Wed, 9 Feb 2011 10:34:02 -0700 Subject: [PATCH] regexec.c: Give context for ANYOFV call This converts one case where ANYOFV is now usable to allow it to match more than one character. --- regexec.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/regexec.c b/regexec.c index 8886c25..58fc358 100644 --- a/regexec.c +++ b/regexec.c @@ -1465,10 +1465,9 @@ S_find_byclass(pTHX_ regexp * prog, const regnode *c, char *s, case ANYOFV: case ANYOF: if (utf8_target || OP(c) == ANYOFV) { - REXEC_FBC_UTF8_CLASS_SCAN((ANYOF_FLAGS(c) & ANYOF_NONBITMAP) || - !UTF8_IS_INVARIANT((U8)s[0]) ? - reginclass(prog, c, (U8*)s, 0, utf8_target) : - REGINCLASS(prog, c, (U8*)s)); + STRLEN inclasslen = strend - s; + REXEC_FBC_UTF8_CLASS_SCAN( + reginclass(prog, c, (U8*)s, &inclasslen, utf8_target)); } else { while (s < strend) { -- 2.7.4