diff options
author | George Hopkins <george-hopkins@null.net> | 2024-01-10 15:34:00 +0100 |
---|---|---|
committer | Nico Williams <nico@cryptonector.com> | 2024-01-16 16:01:27 -0600 |
commit | f954e82b144429972a13a95acdf0297e8cc67fa3 (patch) | |
tree | 84524cd5e579558e8a091dda427a57eb66971f43 | |
parent | f51e841fbce326305eccc2d00906ab4af941e88b (diff) |
Provide strptime implementation on all systems
-rw-r--r-- | src/builtin.c | 2 | ||||
-rw-r--r-- | src/util.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/builtin.c b/src/builtin.c index 902490de..0e59bf40 100644 --- a/src/builtin.c +++ b/src/builtin.c @@ -1464,7 +1464,7 @@ static jv f_strptime(jq_state *jq, jv a, jv b) { */ set_tm_wday(&tm); set_tm_yday(&tm); -#elif defined(WIN32) +#elif defined(WIN32) || !defined(HAVE_STRPTIME) set_tm_wday(&tm); #else if (tm.tm_wday == 8 && tm.tm_mday != 0 && tm.tm_mon >= 0 && tm.tm_mon <= 11) @@ -451,7 +451,7 @@ jv jq_util_input_next_input(jq_util_input_state *state) { return value; } -#if defined(WIN32) && !defined(HAVE_STRPTIME) +#ifndef HAVE_STRPTIME /* http://cvsweb.netbsd.org/bsdweb.cgi/~checkout~/src/lib/libc/time/strptime.c?only_with_tag=HEAD * NetBSD implementation strptime(). * Format description: https://netbsd.gw.com/cgi-bin/man-cgi?strptime+3+NetBSD-current |