Message ID | CAB0OVGpdrPTzq1b=R7rc-rfCWR=O-dA2Wfe+tfMYODNXSAcQww@mail.gmail.com |
---|---|
State | Accepted |
Headers | show |
2018-04-16 1:33 GMT+02:00, Carl Eugen Hoyos <ceffmpeg@gmail.com>: > Hi! > > Attached patch is supposed to silence a user-reported warning when > inet_aton() is missing but getaddrinfo() is supported. > Untested. Ping? Thank you, Carl Eugen
On 16-4-2018 1:33, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote: > Attached patch is supposed to silence a user-reported warning when > inet_aton() is missing but getaddrinfo() is supported. > Untested. > > Please review, Carl Eugen $ make libavformat/os_support.o CC libavformat/os_support.o libavformat/os_support.c: In function 'ff_poll': libavformat/os_support.c:248:23: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits] if (fds[i].fd < 0) ^ The warning this patch is for is gone now. Thanks. -- Reino
2018-04-22 0:52 GMT+02:00, Reino Wijnsma <rwijnsma@xs4all.nl>: > On 16-4-2018 1:33, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote: >> Attached patch is supposed to silence a user-reported warning when >> inet_aton() is missing but getaddrinfo() is supported. >> Untested. >> >> Please review, Carl Eugen > $ make libavformat/os_support.o > CC libavformat/os_support.o > libavformat/os_support.c: In function 'ff_poll': > libavformat/os_support.c:248:23: warning: comparison of unsigned expression > < 0 is always false [-Wtype-limits] > if (fds[i].fd < 0) > ^ > > The warning this patch is for is gone now. Pushed this patch. Carl Eugen
From 9d31a8c99953a2144e2f24d79da4cbc57987f365 Mon Sep 17 00:00:00 2001 From: Carl Eugen Hoyos <ceffmpeg@gmail.com> Date: Mon, 16 Apr 2018 01:28:47 +0200 Subject: [PATCH] lavf/os_support: Only compile inet_aton() if getaddrinfo() is needed. Silences a warning: libavformat/os_support.c:49:12: warning: 'inet_aton' defined but not used Reported-by: Reino Wijnsma --- libavformat/os_support.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/os_support.c b/libavformat/os_support.c index 099d7b5..15cea7f 100644 --- a/libavformat/os_support.c +++ b/libavformat/os_support.c @@ -43,6 +43,7 @@ #include "network.h" +#if !HAVE_GETADDRINFO #if !HAVE_INET_ATON #include <stdlib.h> @@ -62,7 +63,6 @@ static int inet_aton(const char *str, struct in_addr *add) } #endif /* !HAVE_INET_ATON */ -#if !HAVE_GETADDRINFO int ff_getaddrinfo(const char *node, const char *service, const struct addrinfo *hints, struct addrinfo **res) { -- 1.7.10.4