diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2008-01-30 13:54:20 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2008-01-30 13:54:20 +0000 |
commit | 4becae174a3301eac5955f7900d3eef66728e440 (patch) | |
tree | 556f52823f113050a8952717fb32e79a2022e589 /syslogd.c | |
parent | 57cf2138522f3dacf26ea30c6f32a800def70209 (diff) | |
download | rsyslog-4becae174a3301eac5955f7900d3eef66728e440.tar.gz rsyslog-4becae174a3301eac5955f7900d3eef66728e440.tar.xz rsyslog-4becae174a3301eac5955f7900d3eef66728e440.zip |
- fixed a bug that could cause invalid string handling via strerror_r
varmojfekoj provided the patch - many thanks!
- adopted varmojfekoj's patch to v3, some more sterror_r's ;)
Diffstat (limited to 'syslogd.c')
-rw-r--r-- | syslogd.c | 15 |
1 files changed, 0 insertions, 15 deletions
@@ -4132,21 +4132,6 @@ int decode(uchar *name, struct code *codetab) } - -char *rs_strerror_r(int errnum, char *buf, size_t buflen) { -#ifdef STRERROR_R_CHAR_P - char *p = strerror_r(errnum, buf, buflen); - if (p != buf) { - strncpy(buf, p, buflen); - buf[buflen - 1] = '\0'; - } -#else - strerror_r(errnum, buf, buflen); -#endif - return buf; -} - - /* * The following function is resposible for handling a SIGHUP signal. Since * we are now doing mallocs/free as part of init we had better not being |