summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-01-31 17:14:23 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2012-01-31 17:14:23 +0100
commit793155415708271d94f1238d5294c08ad3831d3a (patch)
tree80b2142274d9d15f7213ef407b5748b9cd493019
parent529aaa7f5739d69f81b9abba854f42f16e1b2758 (diff)
downloadrsyslog-793155415708271d94f1238d5294c08ad3831d3a.tar.gz
rsyslog-793155415708271d94f1238d5294c08ad3831d3a.tar.xz
rsyslog-793155415708271d94f1238d5294c08ad3831d3a.zip
stats: generate friendly name for action queues, if possible
-rw-r--r--action.c9
-rw-r--r--configure.ac2
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])])