aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/stdtime/strptime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/stdtime/strptime.c b/lib/libc/stdtime/strptime.c
index 6214398f09e0..78cef6bf839e 100644
--- a/lib/libc/stdtime/strptime.c
+++ b/lib/libc/stdtime/strptime.c
@@ -291,7 +291,7 @@ label:
if (c == 'H' || c == 'k') {
if (i > 23)
return (NULL);
- } else if (i > 12)
+ } else if (i == 0 || i > 12)
return (NULL);
tm->tm_hour = i;