aboutsummaryrefslogtreecommitdiffstats
path: root/builtin.c
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2021-09-26 20:56:19 +0300
committerArnold D. Robbins <arnold@skeeve.com>2021-09-26 20:56:19 +0300
commitf597ee8f9ac128f88f85639ffbce6d7248776f75 (patch)
tree2f6a49a8743a0b5310a29986ffe3c084742afaa9 /builtin.c
parent8d8cd2e6e75399b9f8b1e0517dcfdb1a80cd1e3f (diff)
downloadegawk-f597ee8f9ac128f88f85639ffbce6d7248776f75.tar.gz
egawk-f597ee8f9ac128f88f85639ffbce6d7248776f75.tar.bz2
egawk-f597ee8f9ac128f88f85639ffbce6d7248776f75.zip
Update FIXME and comments and builtin.c:do_mktime.
Diffstat (limited to 'builtin.c')
-rw-r--r--builtin.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/builtin.c b/builtin.c
index cf0c98e3..d7ba82c9 100644
--- a/builtin.c
+++ b/builtin.c
@@ -2121,10 +2121,12 @@ do_mktime(int nargs)
& hour, & minute, & second,
& dst);
+ // 9/2021: I've been told that according to the ISO 8601-1:2019 spec,
+ // hour cannot be 24. So the check for hour > 23 is valid.
if ( do_lint /* Ready? Set! Go: */
&& ( (second < 0 || second > 60)
|| (minute < 0 || minute > 59)
- || (hour < 0 || hour > 23) /* FIXME ISO 8601 allows 24 ? */
+ || (hour < 0 || hour > 23)
|| (day < 1 || day > 31)
|| (month < 1 || month > 12) ))
lintwarn(_("mktime: at least one of the values is out of the default range"));