summaryrefslogtreecommitdiffstats
path: root/plugins/imfile
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2008-06-27 12:52:45 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2008-06-27 12:52:45 +0200
commit3f6c73a8b7ff2c6d9c931876d823f2b4ef6bbea2 (patch)
treea147c4dbda59de0675b0c2a5e80a2b6f97569691 /plugins/imfile
parentd4518082362afebef9400bcbf46e38228de83bf1 (diff)
downloadrsyslog-3f6c73a8b7ff2c6d9c931876d823f2b4ef6bbea2.tar.gz
rsyslog-3f6c73a8b7ff2c6d9c931876d823f2b4ef6bbea2.tar.xz
rsyslog-3f6c73a8b7ff2c6d9c931876d823f2b4ef6bbea2.zip
added (internal) error codes to error messages
Also added redirector to web description of error codes closes bug http://bugzilla.adiscon.com/show_bug.cgi?id=20
Diffstat (limited to 'plugins/imfile')
-rw-r--r--plugins/imfile/imfile.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/imfile/imfile.c b/plugins/imfile/imfile.c
index d4a332eb..dbdf6b94 100644
--- a/plugins/imfile/imfile.c
+++ b/plugins/imfile/imfile.c
@@ -318,7 +318,7 @@ ENDrunInput
BEGINwillRun
CODESTARTwillRun
if(iFilPtr == 0) {
- errmsg.LogError(NO_ERRCODE, "No files configured to be monitored");
+ errmsg.LogError(0, RS_RET_NO_RUN, "No files configured to be monitored");
ABORT_FINALIZE(RS_RET_NO_RUN);
}
@@ -447,21 +447,21 @@ static rsRetVal addMonitor(void __attribute__((unused)) *pVal, uchar *pNewVal)
pThis = &files[iFilPtr];
/* TODO: check for strdup() NULL return */
if(pszFileName == NULL) {
- errmsg.LogError(NO_ERRCODE, "imfile error: no file name given, file monitor can not be created");
+ errmsg.LogError(0, RS_RET_CONFIG_ERROR, "imfile error: no file name given, file monitor can not be created");
ABORT_FINALIZE(RS_RET_CONFIG_ERROR);
} else {
pThis->pszFileName = (uchar*) strdup((char*) pszFileName);
}
if(pszFileTag == NULL) {
- errmsg.LogError(NO_ERRCODE, "imfile error: no tag value given , file monitor can not be created");
+ errmsg.LogError(0, RS_RET_CONFIG_ERROR, "imfile error: no tag value given , file monitor can not be created");
ABORT_FINALIZE(RS_RET_CONFIG_ERROR);
} else {
pThis->pszTag = (uchar*) strdup((char*) pszFileTag);
}
if(pszStateFile == NULL) {
- errmsg.LogError(NO_ERRCODE, "imfile error: not state file name given, file monitor can not be created");
+ errmsg.LogError(0, RS_RET_CONFIG_ERROR, "imfile error: not state file name given, file monitor can not be created");
ABORT_FINALIZE(RS_RET_CONFIG_ERROR);
} else {
pThis->pszStateFile = (uchar*) strdup((char*) pszStateFile);
@@ -470,7 +470,7 @@ static rsRetVal addMonitor(void __attribute__((unused)) *pVal, uchar *pNewVal)
pThis->iSeverity = iSeverity;
pThis->iFacility = iFacility;
} else {
- errmsg.LogError(NO_ERRCODE, "Too many file monitors configured - ignoring this one");
+ errmsg.LogError(0, RS_RET_OUT_OF_DESRIPTORS, "Too many file monitors configured - ignoring this one");
ABORT_FINALIZE(RS_RET_OUT_OF_DESRIPTORS);
}