From: CMD <80255379+iCMDdev@users.noreply.github.com> Date: Wed, 10 Jul 2024 10:16:29 +0000 (+0300) Subject: hostip: skip error check for infallible function call X-Git-Tag: curl-8_9_0~69 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c2e427cc939a3270e528ec078334fa8ff79f180f;p=thirdparty%2Fcurl.git hostip: skip error check for infallible function call Closes #14147 --- diff --git a/lib/hostip.c b/lib/hostip.c index 122e07ec98..2c1f08e744 100644 --- a/lib/hostip.c +++ b/lib/hostip.c @@ -536,8 +536,8 @@ static struct Curl_addrinfo *get_localhost6(int port, const char *name) sa6.sin6_port = htons(port16); sa6.sin6_flowinfo = 0; sa6.sin6_scope_id = 0; - if(Curl_inet_pton(AF_INET6, "::1", ipv6) < 1) - return NULL; + + (void)Curl_inet_pton(AF_INET6, "::1", ipv6); memcpy(&sa6.sin6_addr, ipv6, sizeof(ipv6)); ca->ai_flags = 0;