diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2009-10-08 16:36:17 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2009-10-08 16:36:17 +0200 |
commit | ec56b763b83677d1e9cd02a7ae610caf62e902bb (patch) | |
tree | be7717d7db2fc5bf49b29fa1eb930d1ac51ebfa3 /runtime/parser.c | |
parent | d85efd07e006d4d9031019aa9ac9757d303a8b36 (diff) | |
download | rsyslog-ec56b763b83677d1e9cd02a7ae610caf62e902bb.tar.gz rsyslog-ec56b763b83677d1e9cd02a7ae610caf62e902bb.tar.xz rsyslog-ec56b763b83677d1e9cd02a7ae610caf62e902bb.zip |
bugfix in debug system and more instrumentation to find an issue
bugfix: debug string larger than 1K were improperly displayed. Max size
is now 32K, and if a string is even longer it is meaningful truncated.
Diffstat (limited to 'runtime/parser.c')
-rw-r--r-- | runtime/parser.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/runtime/parser.c b/runtime/parser.c index 466066e7..3c90c447 100644 --- a/runtime/parser.c +++ b/runtime/parser.c @@ -231,14 +231,14 @@ sanitizeMessage(msg_t *pMsg) * can not handle it! -- rgerhards, 2009-08-26 */ if(pszMsg[iSrc] == '\0' || bEscapeCCOnRcv) { - /* we are configured to escape control characters. Please note - * that this most probably break non-western character sets like - * Japanese, Korean or Chinese. rgerhards, 2007-07-17 - */ - pDst[iDst++] = cCCEscapeChar; - pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0300) >> 6); - pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0070) >> 3); - pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0007)); + /* we are configured to escape control characters. Please note + * that this most probably break non-western character sets like + * Japanese, Korean or Chinese. rgerhards, 2007-07-17 + */ + pDst[iDst++] = cCCEscapeChar; + pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0300) >> 6); + pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0070) >> 3); + pDst[iDst++] = '0' + ((pszMsg[iSrc] & 0007)); } } else { pDst[iDst++] = pszMsg[iSrc]; |