From 3c59d60049aa7f9a6624d77870558ceed9b8df4e Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Tue, 14 Jun 2016 14:08:34 +0200 Subject: [PATCH] cuda: make sure we don't use cuda in proto detect --- src/app-layer-detect-proto.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/app-layer-detect-proto.c b/src/app-layer-detect-proto.c index fb25b5b352..541fa24e90 100644 --- a/src/app-layer-detect-proto.c +++ b/src/app-layer-detect-proto.c @@ -1530,6 +1530,12 @@ int AppLayerProtoDetectSetup(void) uint16_t spm_matcher = SinglePatternMatchDefaultMatcher(); uint16_t mpm_matcher = PatternMatchDefaultMatcher(); +#ifdef __SC_CUDA_SUPPORT__ + /* CUDA won't work here, so fall back to AC */ + if (mpm_matcher == MPM_AC_CUDA) + mpm_matcher = DEFAULT_MPM; +#endif + alpd_ctx.spm_global_thread_ctx = SpmInitGlobalThreadCtx(spm_matcher); if (alpd_ctx.spm_global_thread_ctx == NULL) { SCLogError(SC_ERR_FATAL, "Unable to alloc SpmGlobalThreadCtx."); -- 2.47.2