]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
wolfssl: fix compiler error without IPv6
authorDaniel Stenberg <daniel@haxx.se>
Mon, 7 Mar 2022 07:40:47 +0000 (08:40 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 7 Mar 2022 08:47:26 +0000 (09:47 +0100)
Reported-by: Joseph Chen
Fixes #8550
Closes #8552

lib/vtls/wolfssl.c

index eae55683094626eba12aa4090166bf4c7be40200..09ec739c00a953ae5d940e8732243273119e872b 100644 (file)
@@ -462,9 +462,9 @@ wolfssl_connect_step1(struct Curl_easy *data, struct connectdata *conn,
     const char * const hostname = SSL_HOST_NAME();
     size_t hostname_len = strlen(hostname);
     if((hostname_len < USHRT_MAX) &&
-       (0 == Curl_inet_pton(AF_INET, hostname, &addr4)) &&
+       !Curl_inet_pton(AF_INET, hostname, &addr4)
 #ifdef ENABLE_IPV6
-       (0 == Curl_inet_pton(AF_INET6, hostname, &addr6))
+       && !Curl_inet_pton(AF_INET6, hostname, &addr6)
 #endif
       ) {
       size_t snilen;