From 3967bd5517e7ab57fd82d7ce9b70dac16057b8f7 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Fri, 7 Feb 2014 11:04:32 +0100 Subject: [PATCH] app-layer: fix AppLayerParserProtocolIsTxEventAware AppLayerParserProtocolIsTxEventAware would check if a proto is tx event aware by checking if it had registered a StateHasEvents function. However, this is an optimization function. This patch changes it to use the StateGetEvents function instead, which is a better indicator. --- src/app-layer-parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app-layer-parser.c b/src/app-layer-parser.c index b33a0144f7..2665648739 100644 --- a/src/app-layer-parser.c +++ b/src/app-layer-parser.c @@ -931,7 +931,7 @@ int AppLayerParserProtocolIsTxEventAware(uint8_t ipproto, AppProto alproto) { SCEnter(); int ipproto_map = FlowGetProtoMapping(ipproto); - int r = (alp_ctx.ctxs[ipproto_map][alproto].StateHasEvents == NULL) ? 0 : 1; + int r = (alp_ctx.ctxs[ipproto_map][alproto].StateGetEvents == NULL) ? 0 : 1; SCReturnInt(r); } -- 2.47.2