summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-04-16 18:57:51 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2012-04-16 18:57:51 +0200
commit7a8b99ebe9a0aea956f44fbe6e584597445b6a7a (patch)
treed14bd05e00a5edd7fc61a66217d28522c07c4585
parent1acde66c3274c57d084146621d4124eaaef9ccf9 (diff)
downloadrsyslog-7a8b99ebe9a0aea956f44fbe6e584597445b6a7a.tar.gz
rsyslog-7a8b99ebe9a0aea956f44fbe6e584597445b6a7a.tar.xz
rsyslog-7a8b99ebe9a0aea956f44fbe6e584597445b6a7a.zip
bugfix/imuxsock: solving abort if hostname was not set
-rw-r--r--ChangeLog3
-rw-r--r--plugins/imuxsock/imuxsock.c4
2 files changed, 5 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 4b795656..d9491ca6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,7 @@
---------------------------------------------------------------------------
+Version 6.3.9 [DEVEL] 2012-04-??
+- bugfix/imuxsock: solving abort if hostname was not set
+---------------------------------------------------------------------------
Version 6.3.8 [DEVEL] 2012-04-16
- added $PStatJSON directive to permit stats records in JSON format
- added "date-unixtimestamp" property replacer option to format as a
diff --git a/plugins/imuxsock/imuxsock.c b/plugins/imuxsock/imuxsock.c
index c97e6b28..1c8a05e5 100644
--- a/plugins/imuxsock/imuxsock.c
+++ b/plugins/imuxsock/imuxsock.c
@@ -377,13 +377,13 @@ addListner(instanceConf_t *inst)
} else {
listeners[nfd].bParseHost = 0;
}
- CHKiRet(prop.Construct(&(listeners[nfd].hostName)));
if(inst->pLogHostName == NULL) {
listeners[nfd].hostName = NULL;
} else {
+ CHKiRet(prop.Construct(&(listeners[nfd].hostName)));
CHKiRet(prop.SetString(listeners[nfd].hostName, inst->pLogHostName, ustrlen(inst->pLogHostName)));
+ CHKiRet(prop.ConstructFinalize(listeners[nfd].hostName));
}
- CHKiRet(prop.ConstructFinalize(listeners[nfd].hostName));
if(inst->ratelimitInterval > 0) {
if((listeners[nfd].ht = create_hashtable(100, hash_from_key_fn, key_equals_fn, NULL)) == NULL) {
/* in this case, we simply turn off rate-limiting */