diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2007-11-21 10:52:19 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2007-11-21 10:52:19 +0000 |
commit | 8d606ea26d5fc79b845bafbc08d979ecc2ba0529 (patch) | |
tree | f17916ff1579340b723b9253cdab6d117697ab37 /cfsysline.h | |
parent | 214c7bd7f8552f0a07a15373b4a222da6e9e6ba6 (diff) | |
download | rsyslog-8d606ea26d5fc79b845bafbc08d979ecc2ba0529.tar.gz rsyslog-8d606ea26d5fc79b845bafbc08d979ecc2ba0529.tar.xz rsyslog-8d606ea26d5fc79b845bafbc08d979ecc2ba0529.zip |
added an identifier to command handler table - need to identify which
command handler entries need to be removed when module is unloaded
Diffstat (limited to 'cfsysline.h')
-rw-r--r-- | cfsysline.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/cfsysline.h b/cfsysline.h index 607ac40e..a7fad234 100644 --- a/cfsysline.h +++ b/cfsysline.h @@ -46,6 +46,10 @@ struct cslCmdHdlr_s { /* config file sysline parse entry */ ecslCmdHdrlType eType; /* which type of handler is this? */ rsRetVal (*cslCmdHdlr)(); /* function pointer to use with handler (params depending on eType) */ void *pData; /* user-supplied data pointer */ + void *pOwnerCookie; /* a pointer to the owner of this handler. This is important if + * the handler for a specifc owner needs to be removed. Most often, this + * is an actual pointer to a module - may be anything, but must be unique. + */ }; typedef struct cslCmdHdlr_s cslCmdHdlr_t; @@ -61,7 +65,7 @@ struct cslCmd_s { /* config file sysline parse entry */ typedef struct cslCmd_s cslCmd_t; /* prototypes */ -rsRetVal regCfSysLineHdlr(uchar *pCmdName, int bChainingPermitted, ecslCmdHdrlType eType, rsRetVal (*pHdlr)(), void *pData); +rsRetVal regCfSysLineHdlr(uchar *pCmdName, int bChainingPermitted, ecslCmdHdrlType eType, rsRetVal (*pHdlr)(), void *pData, void *pOwnerCookie); rsRetVal unregCfSysLineHdlrs(void); rsRetVal processCfSysLineCommand(uchar *pCmd, uchar **p); rsRetVal cfsyslineInit(void); |