From 284c3cf68a2734400120954a7c60ff28cd3a3172 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Mon, 9 Feb 2015 08:35:30 +0100 Subject: [PATCH] output/tx: bail early if no flow --- src/output-tx.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/output-tx.c b/src/output-tx.c index c893893fbc..edb198ad97 100644 --- a/src/output-tx.c +++ b/src/output-tx.c @@ -135,14 +135,15 @@ int OutputRegisterTxLogger(LoggerId id, const char *name, AppProto alproto, static TmEcode OutputTxLog(ThreadVars *tv, Packet *p, void *thread_data) { DEBUG_VALIDATE_BUG_ON(thread_data == NULL); + if (p->flow == NULL) + return TM_ECODE_OK; + if (list == NULL) { /* No child loggers registered. */ return TM_ECODE_OK; } OutputLoggerThreadData *op_thread_data = (OutputLoggerThreadData *)thread_data; - if (p->flow == NULL) - return TM_ECODE_OK; Flow * const f = p->flow; const uint8_t ipproto = f->proto;