diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2007-07-31 07:51:43 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2007-07-31 07:51:43 +0000 |
commit | c135ef6de2355c9b1c9f69a1df41871e55f55cda (patch) | |
tree | 3e6989bbdcd5f1f644bb1e4eed91415d6c55e204 /syslogd.c | |
parent | 4d162e6a580da3bbbe0f2da4696a77ad9da44161 (diff) | |
download | rsyslog-c135ef6de2355c9b1c9f69a1df41871e55f55cda.tar.gz rsyslog-c135ef6de2355c9b1c9f69a1df41871e55f55cda.tar.bz2 rsyslog-c135ef6de2355c9b1c9f69a1df41871e55f55cda.zip |
- moved the SetCCEscapeCharacter config file directive to cfsysline.c and
also generalized it for further use while doing so
Diffstat (limited to 'syslogd.c')
-rw-r--r-- | syslogd.c | 24 |
1 files changed, 1 insertions, 23 deletions
@@ -3511,28 +3511,6 @@ static void doModLoad(uchar **pp) skipWhiteSpace(pp); /* skip over any whitespace */ } - -/* parse the control character escape prefix and store it. - * added 2007-07-17 by rgerhards - */ -static void doControlCharEscPrefix(uchar **pp) -{ - assert(pp != NULL); - assert(*pp != NULL); - - skipWhiteSpace(pp); /* skip over any whitespace */ - - /* if we are not at a '\0', we have our new char - no validity checks here... */ - if(**pp == '\0') { - logerror("No Control Character Prefix Character given - ignoring directive"); - } else { - cCCEscapeChar = **pp; - ++(*pp); /* eat processed char */ - } - - skipWhiteSpace(pp); /* skip over any whitespace */ -} - /* parse and interpret a $-config line that starts with * a name (this is common code). It is parsed to the name * and then the proper sub-function is called to handle @@ -3647,7 +3625,7 @@ void cfsysline(uchar *p) } else if(!strcasecmp((char*) szCmd, "repeatedmsgreduction")) { doBinaryOptionLine(&p, NULL, &bReduceRepeatMsgs); } else if(!strcasecmp((char*) szCmd, "controlcharacterescapeprefix")) { - doControlCharEscPrefix(&p); + doGetChar(&p, NULL, &cCCEscapeChar); } else if(!strcasecmp((char*) szCmd, "escapecontrolcharactersonreceive")) { doBinaryOptionLine(&p, NULL, &bEscapeCCOnRcv); } else if(!strcasecmp((char*) szCmd, "dropmsgswithmaliciousdnsptrrecords")) { |