summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog14
-rw-r--r--plugins/mmjsonparse/mmjsonparse.c2
-rw-r--r--runtime/msg.c13
3 files changed, 26 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 473d8e98..5b203ae8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -11,6 +11,14 @@ Version 7.3.0 [devel] 2012-10-09
This is controlled by the new action parameter "VeryReliableZip".
---------------------------------------------------------------------------
Version 7.1.11 [beta] 2012-10-??
+- bugfix: do not crash if set statement is used with date field
+ Thanks to Miloslav Trmač for the patch.
+- change lumberjack cookie to "@cee" from "@cee "
+ CEE originally specified the cookie with SP, whereas other lumberjack
+ tools used it without space. In order to keep interop with lumberjack,
+ we now use the cookie without space as well. I hope this can be changed
+ in CEE as well when it is released at a later time.
+ Thanks to Miloslav Trmač for pointing this out and a similiar v7 patch.
- added deprecated note to omruleset (plus clue to use "call")
- added deprecated note to discard action (plus clue to use "stop")
---------------------------------------------------------------------------
@@ -171,6 +179,12 @@ Version 6.5.0 [devel] 2012-08-28
http://bugzilla.adiscon.com/show_bug.cgi?id=353
---------------------------------------------------------------------------
Version 6.4.3 [V6-STABLE] 2012-??-??
+- change lumberjack cookie to "@cee" from "@cee "
+ CEE originally specified the cookie with SP, whereas other lumberjack
+ tools used it without space. In order to keep interop with lumberjack,
+ we now use the cookie without space as well. I hope this can be changed
+ in CEE as well when it is released at a later time.
+ Thanks to Miloslav Trmač for pointing this out and a similiar v7 patch.
- bugfix: comments inside objects (e.g. action()) were not properly handled
- bugfix: sysklogd-emulating standard template was no longer present in v6
This was obviously lost during the transition to the new config format.
diff --git a/plugins/mmjsonparse/mmjsonparse.c b/plugins/mmjsonparse/mmjsonparse.c
index 68f5e74c..da5cfb51 100644
--- a/plugins/mmjsonparse/mmjsonparse.c
+++ b/plugins/mmjsonparse/mmjsonparse.c
@@ -138,7 +138,7 @@ finalize_it:
RETiRet;
}
-#define COOKIE "@cee: "
+#define COOKIE "@cee:"
#define LEN_COOKIE (sizeof(COOKIE)-1)
BEGINdoAction
msg_t *pMsg;
diff --git a/runtime/msg.c b/runtime/msg.c
index d3c814e2..d874178b 100644
--- a/runtime/msg.c
+++ b/runtime/msg.c
@@ -2698,6 +2698,7 @@ uchar *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe,
uchar *pBuf;
int iLen;
short iOffs;
+ enum tplFormatTypes datefmt;
BEGINfunc
assert(pMsg != NULL);
@@ -2717,7 +2718,11 @@ uchar *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe,
bufLen = getMSGLen(pMsg);
break;
case PROP_TIMESTAMP:
- pRes = (uchar*)getTimeReported(pMsg, pTpe->data.field.eDateFormat);
+ if (pTpe != NULL)
+ datefmt = pTpe->data.field.eDateFormat;
+ else
+ datefmt = tplFmtDefault;
+ pRes = (uchar*)getTimeReported(pMsg, datefmt);
break;
case PROP_HOSTNAME:
pRes = (uchar*)getHOSTNAME(pMsg);
@@ -2767,7 +2772,11 @@ uchar *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe,
pRes = (uchar*)getSeverityStr(pMsg);
break;
case PROP_TIMEGENERATED:
- pRes = (uchar*)getTimeGenerated(pMsg, pTpe->data.field.eDateFormat);
+ if (pTpe != NULL)
+ datefmt = pTpe->data.field.eDateFormat;
+ else
+ datefmt = tplFmtDefault;
+ pRes = (uchar*)getTimeGenerated(pMsg, datefmt);
break;
case PROP_PROGRAMNAME:
pRes = getProgramName(pMsg, LOCK_MUTEX);