diff options
author | dt <dt@FreeBSD.org> | 1999-05-06 13:57:57 +0000 |
---|---|---|
committer | dt <dt@FreeBSD.org> | 1999-05-06 13:57:57 +0000 |
commit | 14f270d531fd127b5de0e208cc9d44257284ec35 (patch) | |
tree | 6019469cc8915f0f836fce246e9ed018ff4063fd /usr.sbin/syslogd | |
parent | 90f99b8c30747c59b7882e4f1ef110353b432e21 (diff) | |
download | FreeBSD-src-14f270d531fd127b5de0e208cc9d44257284ec35.zip FreeBSD-src-14f270d531fd127b5de0e208cc9d44257284ec35.tar.gz |
readklog(): rename variable 'l' to 'len', to avoid possible confusion with 'i'
and '1'.
Requested by: mckay
Diffstat (limited to 'usr.sbin/syslogd')
-rw-r--r-- | usr.sbin/syslogd/syslogd.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/usr.sbin/syslogd/syslogd.c b/usr.sbin/syslogd/syslogd.c index 8b03d7c..8b513b9 100644 --- a/usr.sbin/syslogd/syslogd.c +++ b/usr.sbin/syslogd/syslogd.c @@ -42,7 +42,7 @@ static const char copyright[] = static char sccsid[] = "@(#)syslogd.c 8.3 (Berkeley) 4/4/94"; #endif static const char rcsid[] = - "$Id: syslogd.c,v 1.49 1999/05/02 17:44:16 dt Exp $"; + "$Id: syslogd.c,v 1.50 1999/05/04 18:03:59 des Exp $"; #endif /* not lint */ /* @@ -584,13 +584,13 @@ void readklog() { char *p, *q, line[MAXLINE + 1]; - int l, i; + int len, i; - l = 0; + len = 0; for (;;) { - i = read(fklog, line + l, MAXLINE - 1 - l); + i = read(fklog, line + len, MAXLINE - 1 - len); if (i > 0) - line[i + l] = '\0'; + line[i + len] = '\0'; else if (i < 0 && errno != EINTR && errno != EAGAIN) { logerror("klog"); fklog = -1; @@ -602,15 +602,15 @@ readklog() *q = '\0'; printsys(p); } - l = strlen(p); - if (l >= MAXLINE - 1) { + len = strlen(p); + if (len >= MAXLINE - 1) { printsys(p); - l = 0; + len = 0; } - if (l > 0) - memmove(line, p, l + 1); + if (len > 0) + memmove(line, p, len + 1); } - if (l > 0) + if (len > 0) printsys(line); } |