From 7a8b99ebe9a0aea956f44fbe6e584597445b6a7a Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Mon, 16 Apr 2012 18:57:51 +0200 Subject: bugfix/imuxsock: solving abort if hostname was not set --- ChangeLog | 3 +++ plugins/imuxsock/imuxsock.c | 4 ++-- 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 */ -- cgit