diff options
Diffstat (limited to 'sysklogd')
-rw-r--r-- | sysklogd/syslogd.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sysklogd/syslogd.c b/sysklogd/syslogd.c index 52642e302..e5ddd3b82 100644 --- a/sysklogd/syslogd.c +++ b/sysklogd/syslogd.c | |||
@@ -55,7 +55,7 @@ | |||
55 | #define __LOG_FILE "/var/log/messages" | 55 | #define __LOG_FILE "/var/log/messages" |
56 | 56 | ||
57 | /* Path to the unix socket */ | 57 | /* Path to the unix socket */ |
58 | char lfile[BUFSIZ] = ""; | 58 | static char lfile[BUFSIZ] = ""; |
59 | 59 | ||
60 | static char *logFilePath = __LOG_FILE; | 60 | static char *logFilePath = __LOG_FILE; |
61 | 61 | ||
@@ -390,18 +390,18 @@ static void domark(int sig) | |||
390 | static const int BUFSIZE = 1023; | 390 | static const int BUFSIZE = 1023; |
391 | static int serveConnection (int conn) | 391 | static int serveConnection (int conn) |
392 | { | 392 | { |
393 | RESERVE_BB_BUFFER(buf, BUFSIZE + 1); | 393 | RESERVE_BB_BUFFER(tmpbuf, BUFSIZE + 1); |
394 | int n_read; | 394 | int n_read; |
395 | 395 | ||
396 | while ((n_read = read (conn, buf, BUFSIZE )) > 0) { | 396 | while ((n_read = read (conn, tmpbuf, BUFSIZE )) > 0) { |
397 | 397 | ||
398 | int pri = (LOG_USER | LOG_NOTICE); | 398 | int pri = (LOG_USER | LOG_NOTICE); |
399 | char line[ BUFSIZE + 1 ]; | 399 | char line[ BUFSIZE + 1 ]; |
400 | unsigned char c; | 400 | unsigned char c; |
401 | 401 | ||
402 | char *p = buf, *q = line; | 402 | char *p = tmpbuf, *q = line; |
403 | 403 | ||
404 | buf[ n_read - 1 ] = '\0'; | 404 | tmpbuf[ n_read - 1 ] = '\0'; |
405 | 405 | ||
406 | while (p && (c = *p) && q < &line[ sizeof (line) - 1 ]) { | 406 | while (p && (c = *p) && q < &line[ sizeof (line) - 1 ]) { |
407 | if (c == '<') { | 407 | if (c == '<') { |