From a959ee8bf656532df6e7356f8b6e2ce84fd62b58 Mon Sep 17 00:00:00 2001 From: toorls Date: Wed, 12 Oct 2022 06:24:38 -0700 Subject: [PATCH] fix asn1 time bug on windows --- src/asn1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/asn1.c b/src/asn1.c index b7a77ecd..77195876 100644 --- a/src/asn1.c +++ b/src/asn1.c @@ -1193,7 +1193,7 @@ int asn1_utc_time_from_der_ex(int tag, time_t *t, const uint8_t **pin, size_t *p } if (len == sizeof("YYMMDDHHMMSSZ")-1) { #ifdef WIN32 - asn1_generalizedtime_to_tm(&tm_val, buf); + asn1_generalizedtime_to_tm(buf, &tm_val); *t = GMSSL_timegm(&tm_val); #else if (!strptime(buf, "%Y%m%d%H%M%SZ", &tm_val)) {