Module Name: src
Committed By: christos
Date: Mon Aug 19 23:50:23 UTC 2024
Modified Files:
src/external/bsd/cron/dist: entry.c
Log Message:
undo previous, we check the range in set_element.
To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/external/bsd/cron/dist/entry.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/bsd/cron/dist/entry.c
diff -u src/external/bsd/cron/dist/entry.c:1.12 src/external/bsd/cron/dist/entry.c:1.13
--- src/external/bsd/cron/dist/entry.c:1.12 Mon Aug 19 19:16:05 2024
+++ src/external/bsd/cron/dist/entry.c Mon Aug 19 19:50:23 2024
@@ -26,7 +26,7 @@
#if 0
static char rcsid[] = "Id: entry.c,v 1.17 2004/01/23 18:56:42 vixie Exp";
#else
-__RCSID("$NetBSD: entry.c,v 1.12 2024/08/19 23:16:05 christos Exp $");
+__RCSID("$NetBSD: entry.c,v 1.13 2024/08/19 23:50:23 christos Exp $");
#endif
#endif
@@ -519,7 +519,7 @@ get_range(bitstr_t *bits, int low, int h
if (!star) {
ch = get_number(&num1, low, names, ch, file, ",- \t\n");
- if (ch == EOF || num1 < 0)
+ if (ch == EOF)
return (EOF);
if (ch != '-') {
@@ -579,7 +579,7 @@ get_range(bitstr_t *bits, int low, int h
* sent as a 0 since there is no offset either.
*/
ch = get_number(&num3, 0, PPC_NULL, ch, file, ", \t\n");
- if (ch == EOF || num3 <= 0)
+ if (ch == EOF || num3 == 0)
return (EOF);
} else {
/* no step. default==1.