From f97c90d12b9ae64a64cde84bb3fa3ca5ee207838 Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Tue, 24 Jul 2007 09:45:19 +0000 Subject: moved discard functionality to an output module --- omfwd.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'omfwd.c') diff --git a/omfwd.c b/omfwd.c index 35159630..74b4c66e 100644 --- a/omfwd.c +++ b/omfwd.c @@ -64,10 +64,20 @@ static const char *sys_h_errlist[] = { "no address, look for MX record" /* NO_ADDRESS */ }; +/* query feature compatibility + */ +static rsRetVal isCompatibleWithFeature(syslogFeature eFeat) +{ + if(eFeat == sFEATURERepeatedMsgReduction) + return RS_RET_OK; + + return RS_RET_INCOMPATIBLE; +} + + /* call the shell action - * returns 0 if it succeeds, something else otherwise */ -int doActionFwd(selector_t *f) +static rsRetVal doActionFwd(selector_t *f) { char *psz; /* temporary buffering */ register unsigned l; @@ -238,7 +248,7 @@ int doActionFwd(selector_t *f) } break; } - return 0; + return RS_RET_OK; } @@ -446,6 +456,8 @@ static rsRetVal queryEtryPt(uchar *name, rsRetVal (**pEtryPoint)()) *pEtryPoint = doActionFwd; } else if(!strcmp((char*) name, "parseSelectorAct")) { *pEtryPoint = parseSelectorAct; + } else if(!strcmp((char*) name, "isCompatibleWithFeature")) { + *pEtryPoint = isCompatibleWithFeature; } /*else if(!strcmp((char*) name, "freeInstance")) { *pEtryPoint = freeInstanceFile; }*/ -- cgit v1.2.3