From 793155415708271d94f1238d5294c08ad3831d3a Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Tue, 31 Jan 2012 17:14:23 +0100 Subject: stats: generate friendly name for action queues, if possible --- action.c | 9 +++++++-- configure.ac | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/action.c b/action.c index f16146c1..e465b826 100644 --- a/action.c +++ b/action.c @@ -348,8 +348,13 @@ actionConstructFinalize(action_t *pThis) CHKiRet(statsobj.ConstructFinalize(pThis->statsobj)); /* create our queue */ - /* find a name for our queue */ - snprintf((char*) pszAName, sizeof(pszAName)/sizeof(uchar), "action %d queue", iActionNbr); + /* find a (friendly) name for our queue */ + if(pThis->pszName == NULL) { + snprintf((char*) pszAName, sizeof(pszAName)/sizeof(uchar), "action %d queue", iActionNbr); + } else { + snprintf((char*) pszAName, sizeof(pszAName)/sizeof(uchar), "%s queue", pThis->pszName); + } + pszAName[63] = '\0'; /* to be on the save side */ /* now check if we can run the action in "firehose mode" during stage one of * its processing (that is before messages are enqueued into the action q). diff --git a/configure.ac b/configure.ac index c6d775af..5bfaf42c 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.61) -AC_INIT([rsyslog],[5.8.6-newstats6],[rsyslog@lists.adiscon.com]) +AC_INIT([rsyslog],[5.8.7-newstats7],[rsyslog@lists.adiscon.com]) AM_INIT_AUTOMAKE m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) -- cgit v1.2.3