From: Javier Blazquez Date: Wed, 24 Jun 2020 20:21:04 +0000 (-0700) Subject: openssl: Fix compilation on Windows when ngtcp2 is enabled X-Git-Tag: curl-7_71_1~24 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ae3d1e04f68b0f3ef5a19118553cd630f8454a3b;p=thirdparty%2Fcurl.git openssl: Fix compilation on Windows when ngtcp2 is enabled - Include wincrypt before OpenSSL includes so that the latter can properly handle any conflicts between the two. Closes https://github.com/curl/curl/pull/5606 --- diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index 790d35862a..c822e6b099 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -31,6 +31,11 @@ #include +/* Wincrypt must be included before anything that could include OpenSSL. */ +#if defined(USE_WIN32_CRYPTO) +#include +#endif + #include "urldata.h" #include "sendf.h" #include "formdata.h" /* for the boundary function */ @@ -48,10 +53,6 @@ #include "strerror.h" #include "curl_printf.h" -#if defined(USE_WIN32_CRYPTO) -#include -#endif - #include #include #include