qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] io: fix build on FreeBSD
@ 2016-02-25 15:31 Ed Maste
  2016-02-25 15:46 ` Daniel P. Berrange
  2016-02-25 16:29 ` Eric Blake
  0 siblings, 2 replies; 7+ messages in thread
From: Ed Maste @ 2016-02-25 15:31 UTC (permalink / raw)
  To: qemu-devel; +Cc: Ed Maste

EAI_ADDRFAMILY is obsolete and FreeBSD/s netdb.h does not provide a
definition.

Signed-off-by: Ed Maste <emaste@freebsd.org>
---
 tests/test-io-channel-socket.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tests/test-io-channel-socket.c b/tests/test-io-channel-socket.c
index 0697363..f4dbd60 100644
--- a/tests/test-io-channel-socket.c
+++ b/tests/test-io-channel-socket.c
@@ -63,7 +63,10 @@ static int check_protocol_support(bool *has_ipv4, bool *has_ipv6)
 
     gaierr = getaddrinfo("::1", NULL, &hints, &ai);
     if (gaierr != 0) {
-        if (gaierr == EAI_ADDRFAMILY ||
+        if (
+#ifdef EAI_ADDRFAMILY
+            gaierr == EAI_ADDRFAMILY ||
+#endif
             gaierr == EAI_FAMILY ||
             gaierr == EAI_NONAME) {
             *has_ipv6 = false;
-- 
2.4.6

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-02-26 14:26 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-25 15:31 [Qemu-devel] [PATCH] io: fix build on FreeBSD Ed Maste
2016-02-25 15:46 ` Daniel P. Berrange
2016-02-25 16:29 ` Eric Blake
2016-02-25 16:32   ` Daniel P. Berrange
2016-02-25 16:37     ` Eric Blake
2016-02-25 16:41       ` Daniel P. Berrange
2016-02-26 14:25         ` Ed Maste

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).