From 7d516b0a6c46177c18aea30b4617f1d2712d48fd Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Wed, 14 Mar 2012 13:51:18 +0100 Subject: added missing initialization of stats counters this was necessary due to refactoring of the stats subsystem ... but should have been done in the first place when this code was written. Thanks to Kaiwang Chen for his analysis of the stats subsystem, which ultimately lead to this patch! --- tcpsrv.c | 1 + 1 file changed, 1 insertion(+) (limited to 'tcpsrv.c') diff --git a/tcpsrv.c b/tcpsrv.c index 86175ff4..dcf407c0 100644 --- a/tcpsrv.c +++ b/tcpsrv.c @@ -128,6 +128,7 @@ addNewLstnPort(tcpsrv_t *pThis, uchar *pszPort) snprintf((char*)statname, sizeof(statname), "%s(%s)", pThis->pszInputName, pszPort); statname[sizeof(statname)-1] = '\0'; /* just to be on the save side... */ CHKiRet(statsobj.SetName(pEntry->stats, statname)); + STATSCOUNTER_INIT(pEntry->ctrSubmit, pEntry->mutCtrSubmit); CHKiRet(statsobj.AddCounter(pEntry->stats, UCHAR_CONSTANT("submitted"), ctrType_IntCtr, &(pEntry->ctrSubmit))); CHKiRet(statsobj.ConstructFinalize(pEntry->stats)); -- cgit