diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2009-07-09 12:25:51 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2009-07-09 12:25:51 +0200 |
commit | cafb951020817cca6b89b5cc6b91f3a8ab86f29a (patch) | |
tree | e95afa136bad2056c20a63bf9652995669250a1d /runtime | |
parent | 33c5bb3c08d7f826862ff78816be82cbe09d17eb (diff) | |
download | rsyslog-cafb951020817cca6b89b5cc6b91f3a8ab86f29a.tar.gz rsyslog-cafb951020817cca6b89b5cc6b91f3a8ab86f29a.tar.xz rsyslog-cafb951020817cca6b89b5cc6b91f3a8ab86f29a.zip |
bugfix: message could be truncated after TAG, often when forwarding
This was a result of an internal processing error if maximum field
sizes had been specified in the property replacer.
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/msg.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/msg.c b/runtime/msg.c index 63ed0083..4d48c895 100644 --- a/runtime/msg.c +++ b/runtime/msg.c @@ -2405,6 +2405,7 @@ char *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe, --iLen; } *pBuf = '\0'; + bufLen -= iLen; /* subtract remaining lenght if the string was smaller! */ if(*pbMustBeFreed == 1) free(pRes); pRes = pBufStart; @@ -2858,7 +2859,6 @@ char *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe, bufLen = strlen(pRes); *pPropLen = bufLen; - /*dbgprintf("MsgGetProp(\"%s\"): \"%s\"\n", pName, pRes); only for verbose debug logging */ ENDfunc return(pRes); } |