aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil/regexp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libutil/regexp.c')
-rw-r--r--src/libutil/regexp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libutil/regexp.c b/src/libutil/regexp.c
index b7d461b3e..235a3c2ac 100644
--- a/src/libutil/regexp.c
+++ b/src/libutil/regexp.c
@@ -714,7 +714,7 @@ rspamd_regexp_search (rspamd_regexp_t *re, const gchar *text, gsize len,
#ifdef HAVE_PCRE_JIT
if (!(re->flags & RSPAMD_REGEXP_FLAG_DISABLE_JIT) && can_jit) {
- if (!g_utf8_validate (mt, remain, NULL)) {
+ if (re->re != re->raw_re && !g_utf8_validate (mt, remain, NULL)) {
msg_err ("bad utf8 input for JIT re");
return FALSE;
}