From: Vsevolod Stakhov Date: Sun, 26 Mar 2017 09:54:48 +0000 (+0100) Subject: [Fix] Do not compile hyperscan with no SSSE3 support X-Git-Tag: 1.5.4~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3307ad5d3a6d7aab44ec949796a2b4d2042539a0;p=thirdparty%2Frspamd.git [Fix] Do not compile hyperscan with no SSSE3 support --- diff --git a/src/hs_helper.c b/src/hs_helper.c index 94e50e7212..208ebe4e4f 100644 --- a/src/hs_helper.c +++ b/src/hs_helper.c @@ -181,6 +181,12 @@ rspamd_rs_compile (struct hs_helper_ctx *ctx, struct rspamd_worker *worker, static struct rspamd_srv_command srv_cmd; gint ncompiled; + if (!(ctx->cfg->libs_ctx->crypto_ctx->cpu_config & CPUID_SSSE3)) { + msg_warn ("CPU doesn't have SSSE3 instructions set " + "required for hyperscan, disable hyperscan compilation"); + return FALSE; + } + if (!rspamd_hs_helper_cleanup_dir (ctx, forced)) { msg_warn ("cannot cleanup cache dir '%s'", ctx->hs_dir); }