summaryrefslogtreecommitdiffstats
path: root/omusrmsg.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2008-03-06 09:59:35 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2008-03-06 09:59:35 +0000
commit24fd07ebe66c56430ca8a752ad1703d29c2f9da4 (patch)
tree01f73c02f158a07993e599f685a6358f3e9c0b42 /omusrmsg.c
parent08b2347039b80b7362c517459723c0c4fdebfd37 (diff)
downloadrsyslog-24fd07ebe66c56430ca8a752ad1703d29c2f9da4.tar.gz
rsyslog-24fd07ebe66c56430ca8a752ad1703d29c2f9da4.tar.xz
rsyslog-24fd07ebe66c56430ca8a752ad1703d29c2f9da4.zip
(tried to) fix logerror() call under BSD (but can not yet compile, so this
may be an error...)
Diffstat (limited to 'omusrmsg.c')
-rw-r--r--omusrmsg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/omusrmsg.c b/omusrmsg.c
index 382f6158..b8d212ac 100644
--- a/omusrmsg.c
+++ b/omusrmsg.c
@@ -58,6 +58,7 @@
#include "syslogd.h"
#include "omusrmsg.h"
#include "module-template.h"
+#include "errmsg.h"
/* portability: */
@@ -71,6 +72,7 @@ MODULE_TYPE_OUTPUT
/* internal structures
*/
DEF_OMOD_STATIC_DATA
+DEFobjCurrIf(errmsg)
typedef struct _instanceData {
int bIsWall; /* 1- is wall, 0 - individual users */
@@ -128,7 +130,7 @@ void setutent(void)
{
assert(BSD_uf == NULL);
if ((BSD_uf = fopen(_PATH_UTMP, "r")) == NULL) {
- logerror(_PATH_UTMP);
+ errmsg.LogError(NO_ERRNO, "%s", _PATH_UTMP);
return;
}
}
@@ -347,6 +349,7 @@ BEGINmodInit(UsrMsg)
CODESTARTmodInit
*ipIFVersProvided = CURR_MOD_IF_VERSION; /* we only support the current interface specification */
CODEmodInit_QueryRegCFSLineHdlr
+ CHKiRet(objUse(errmsg, CORE_COMPONENT));
ENDmodInit
/*