summaryrefslogtreecommitdiffstats
path: root/msg.h
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2008-01-04 16:05:42 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2008-01-04 16:05:42 +0000
commitfaf8e5a3849621acfbd0a0887f2e924a40cb029a (patch)
tree2cc3b3c4342ccded98f56f6ec7bc72cf46c35dc5 /msg.h
parentb95b5ab28407b75467c6cff63359cba9a0a3bd70 (diff)
downloadrsyslog-faf8e5a3849621acfbd0a0887f2e924a40cb029a.tar.gz
rsyslog-faf8e5a3849621acfbd0a0887f2e924a40cb029a.tar.xz
rsyslog-faf8e5a3849621acfbd0a0887f2e924a40cb029a.zip
- begun some work on Msg Object serializiation
- created a kind of general base class
Diffstat (limited to 'msg.h')
-rw-r--r--msg.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/msg.h b/msg.h
index edca576c..d919cc62 100644
--- a/msg.h
+++ b/msg.h
@@ -25,6 +25,7 @@
#ifndef MSG_H_INCLUDED
#define MSG_H_INCLUDED 1
+#include "obj.h"
#include "syslogd-types.h"
#include "template.h"
@@ -44,6 +45,7 @@
* called each time a "copy" is stored somewhere.
*/
struct msg {
+ BEGINobjInstance; /* Data to implement generic object - MUST be the first data element! */
int iRefCount; /* reference counter (0 = unused) */
short iSyslogVers; /* version of syslog protocol
* 0 - RFC 3164
@@ -104,8 +106,10 @@ typedef struct msg msg_t; /* new name */
/* function prototypes
*/
+PROTOTYPEObjClassInit(Msg);
char* getProgramName(msg_t*);
msg_t* MsgConstruct(void);
+rsRetVal MsgSerialize(uchar **ppOutBuf, size_t *pLenBuf, void *pUsr);
void MsgDestruct(msg_t * pM);
msg_t* MsgDup(msg_t* pOld);
msg_t *MsgAddRef(msg_t *pM);