diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2003-06-10 22:58:46 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2003-06-10 22:58:46 +0000 |
commit | a3c95338e9818a500e9c35403dca0ee1b8b7dc12 (patch) | |
tree | aee4bfb3b8668b5cf4defc8961d0657db9899525 /usr.bin | |
parent | b8aaa8bec8414f8e55cf9b61fe0873d242c773b8 (diff) |
Whoops, <= 0 should be < 0. Problem noticed by marc@
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/newsyslog/newsyslog.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/newsyslog/newsyslog.c b/usr.bin/newsyslog/newsyslog.c index 375ddaf7f84..9c06b192328 100644 --- a/usr.bin/newsyslog/newsyslog.c +++ b/usr.bin/newsyslog/newsyslog.c @@ -1,4 +1,4 @@ -/* $OpenBSD: newsyslog.c,v 1.70 2003/06/09 20:43:44 millert Exp $ */ +/* $OpenBSD: newsyslog.c,v 1.71 2003/06/10 22:58:45 millert Exp $ */ /* * Copyright (c) 1999, 2002, 2003 Todd C. Miller <Todd.Miller@courtesan.com> @@ -68,7 +68,7 @@ */ #ifndef lint -static const char rcsid[] = "$OpenBSD: newsyslog.c,v 1.70 2003/06/09 20:43:44 millert Exp $"; +static const char rcsid[] = "$OpenBSD: newsyslog.c,v 1.71 2003/06/10 22:58:45 millert Exp $"; #endif /* not lint */ #ifndef CONF @@ -568,7 +568,7 @@ parse_file(int *nentries) q = parse = missing_field(sob(++parse), errline, lineno); *(parse = son(parse)) = '\0'; l = strtol(q, &ep, 10); - if (l <= 0 || l >= INT_MAX) + if (l < 0 || l >= INT_MAX) errx(1, "%s:%d: interval out of range: %s", conf, lineno, q); working->hours = (int)l; |