hostip: skip error check for infallible function call

Closes #14147
This commit is contained in:
CMD 2024-07-10 13:16:29 +03:00 committed by Daniel Stenberg
parent 5637ca1aab
commit c2e427cc93
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -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;