ffmpeg-6: fix COMPONENT_REVISION
[oi-userland.git] / components / web / wget2 / patches / 02-getaddrinfo.patch
blobbef814b4752bc642f756736a9e3700c812e1889d
2 Upstream PR: https://gitlab.com/gnuwget/wget2/-/merge_requests/530
4 illumos does not support getaddrinfo() with hints where ai_socktype is 0
5 (unspecified) and ai_flags contains AI_NUMERICSERV. Neither, apparently, does
6 Windows.
8 https://www.illumos.org/issues/11616
10 diff -wpruN --no-dereference '--exclude=*.orig' a~/libwget/dns.c a/libwget/dns.c
11 --- a~/libwget/dns.c 1970-01-01 00:00:00
12 +++ a/libwget/dns.c 1970-01-01 00:00:00
13 @@ -227,7 +227,7 @@ static int resolve(int family, int flags
15 struct addrinfo hints = {
16 .ai_family = family,
17 -#ifdef _WIN32
18 +#if defined(_WIN32) || defined(__illumos__)
19 // It looks like on Windows 0 is not a valid option here.
20 // see https://learn.microsoft.com/en-us/windows/win32/api/ws2def/ns-ws2def-addrinfoa
21 // TODO: On Windows, do two calls to getaddrinfo (for TCP and UDP) and merge the results.