diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2007-07-25 10:52:47 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2007-07-25 10:52:47 +0000 |
commit | 36f1b6d7f97c0dd6e96c05876ee7ddeaa5a0a3d5 (patch) | |
tree | 0dc4db7ed2fd7ffa5efba0c4ee246088a91ea2ab /module-template.h | |
parent | a3192ac18ed9df7d95d0c8d5795994e867c85eca (diff) | |
download | rsyslog-36f1b6d7f97c0dd6e96c05876ee7ddeaa5a0a3d5.tar.gz rsyslog-36f1b6d7f97c0dd6e96c05876ee7ddeaa5a0a3d5.tar.xz rsyslog-36f1b6d7f97c0dd6e96c05876ee7ddeaa5a0a3d5.zip |
added new function dbgPrintInstInfo() to omod interface
Diffstat (limited to 'module-template.h')
-rw-r--r-- | module-template.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/module-template.h b/module-template.h index 843440b5..8842f7e4 100644 --- a/module-template.h +++ b/module-template.h @@ -100,6 +100,26 @@ static rsRetVal doAction(selector_t *f)\ return iRet;\ } + +/* dbgPrintInstInfo() + * Extra comments: + * Print debug information about this instance. + */ +#define BEGINdbgPrintInstInfo \ +static rsRetVal dbgPrintInstInfo(selector_t *f, void *pModData)\ +{\ + rsRetVal iRet = RS_RET_OK;\ + instanceData *pData = NULL; + +#define CODESTARTdbgPrintInstInfo \ + assert(f != NULL);\ + pData = (instanceData*) pModData; + +#define ENDdbgPrintInstInfo \ + return iRet;\ +} + + /* parseSelectorAct() * Extra comments: * try to process a selector action line. Checks if the action @@ -121,6 +141,7 @@ static rsRetVal parseSelectorAct(uchar **pp, selector_t *f, void **ppModData)\ return iRet;\ } + /* queryEtryPt() */ #define BEGINqueryEtryPt \ @@ -150,6 +171,8 @@ static rsRetVal queryEtryPt(uchar *name, rsRetVal (**pEtryPoint)())\ *pEtryPoint = parseSelectorAct;\ } else if(!strcmp((char*) name, "isCompatibleWithFeature")) {\ *pEtryPoint = isCompatibleWithFeature;\ + } else if(!strcmp((char*) name, "dbgPrintInstInfo")) {\ + *pEtryPoint = dbgPrintInstInfo;\ } else if(!strcmp((char*) name, "freeInstance")) {\ *pEtryPoint = freeInstance;\ } |