summaryrefslogtreecommitdiffstats
path: root/tools/syslogd.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-04-07 15:42:46 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2012-04-07 15:42:46 +0200
commitd6da57ae0370aeb705f63fd04e575b5ed4684618 (patch)
treed451907714559f5df60eb0cdef6ccbc205c812e4 /tools/syslogd.c
parentd8ce489bae3ae072a2ee605cd90fa0530c9f3446 (diff)
parentbd8d972a975ce794dd71c1c8db724991dd4744a0 (diff)
downloadrsyslog-d6da57ae0370aeb705f63fd04e575b5ed4684618.tar.gz
rsyslog-d6da57ae0370aeb705f63fd04e575b5ed4684618.tar.xz
rsyslog-d6da57ae0370aeb705f63fd04e575b5ed4684618.zip
Merge branch 'v5-stable-newstats'
Conflicts: action.c configure.ac doc/imuxsock.html plugins/imklog/imklog.c plugins/imptcp/imptcp.c plugins/imtcp/imtcp.c plugins/imudp/imudp.c plugins/imuxsock/imuxsock.c runtime/glbl.c runtime/glbl.h runtime/net.c runtime/ruleset.c tcpsrv.h tools/syslogd.c
Diffstat (limited to 'tools/syslogd.c')
-rw-r--r--tools/syslogd.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/tools/syslogd.c b/tools/syslogd.c
index 2e7a1e23..9f6b928b 100644
--- a/tools/syslogd.c
+++ b/tools/syslogd.c
@@ -190,7 +190,6 @@ static rsRetVal GlobalClassExit(void);
rsconf_t *ourConf; /* our config object */
static prop_t *pInternalInputName = NULL; /* there is only one global inputName for all internally-generated messages */
-static prop_t *pLocalHostIP = NULL; /* there is only one global IP for all internally-generated messages */
static uchar *ConfFile = (uchar*) _PATH_LOGCONF; /* read-only after startup */
static char *PidFile = _PATH_LOGPID; /* read-only after startup */
@@ -448,7 +447,8 @@ logmsgInternal(int iErr, int pri, uchar *msg, int flags)
MsgSetRawMsgWOSize(pMsg, (char*)msg);
MsgSetHOSTNAME(pMsg, glbl.GetLocalHostName(), ustrlen(glbl.GetLocalHostName()));
MsgSetRcvFrom(pMsg, glbl.GetLocalHostNameProp());
- MsgSetRcvFromIP(pMsg, pLocalHostIP);
+dbgprintf("ZZZZ: pLocalHostIPIF used!\n");
+ MsgSetRcvFromIP(pMsg, glbl.GetLocalHostIP());
MsgSetMSGoffs(pMsg, 0);
/* check if we have an error code associated and, if so,
* adjust the tag. -- rgerhards, 2008-06-27
@@ -882,8 +882,6 @@ die(int sig)
/* destruct our global properties */
if(pInternalInputName != NULL)
prop.Destruct(&pInternalInputName);
- if(pLocalHostIP != NULL)
- prop.Destruct(&pLocalHostIP);
/* terminate the remaining classes */
GlobalClassExit();
@@ -1793,10 +1791,6 @@ int realMain(int argc, char **argv)
CHKiRet(prop.SetString(pInternalInputName, UCHAR_CONSTANT("rsyslogd"), sizeof("rsyslgod") - 1));
CHKiRet(prop.ConstructFinalize(pInternalInputName));
- CHKiRet(prop.Construct(&pLocalHostIP));
- CHKiRet(prop.SetString(pLocalHostIP, UCHAR_CONSTANT("127.0.0.1"), sizeof("127.0.0.1") - 1));
- CHKiRet(prop.ConstructFinalize(pLocalHostIP));
-
/* get our host and domain names - we need to do this early as we may emit
* error log messages, which need the correct hostname. -- rgerhards, 2008-04-04
*/