From: Jason Ish Date: Fri, 15 Sep 2023 18:35:31 +0000 (-0600) Subject: output-flow: document the name field as for debugging only X-Git-Tag: suricata-8.0.0-beta1~930 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bd81f9f4d3a2fa274ffab6ece6b504d814d3e0f0;p=thirdparty%2Fsuricata.git output-flow: document the name field as for debugging only Ticket: #7227 --- diff --git a/src/output-flow.c b/src/output-flow.c index d738152953..47c8b31f30 100644 --- a/src/output-flow.c +++ b/src/output-flow.c @@ -42,7 +42,10 @@ typedef struct OutputFlowLogger_ { FlowLogger LogFunc; OutputCtx *output_ctx; struct OutputFlowLogger_ *next; + + /** A name for this logger, used for debugging only. */ const char *name; + TmEcode (*ThreadInit)(ThreadVars *, const void *, void **); TmEcode (*ThreadDeinit)(ThreadVars *, void *); void (*ThreadExitPrintStats)(ThreadVars *, void *); @@ -50,6 +53,14 @@ typedef struct OutputFlowLogger_ { static OutputFlowLogger *list = NULL; +/** + * \brief Register a new low-level flow logger. + * + * \param name The name of this logger. Its only used for debugging, + * so choose something unique. + * + * \retval 0 on success, -1 on failure. + */ int OutputRegisterFlowLogger(const char *name, FlowLogger LogFunc, OutputCtx *output_ctx, ThreadInitFunc ThreadInit, ThreadDeinitFunc ThreadDeinit,