From bb765c37acdaea58a3ffdcca6309fa371ee04d07 Mon Sep 17 00:00:00 2001
From: "Timothy B. Terriberry" <tterribe@xiph.org>
Date: Fri, 27 Feb 2015 10:59:51 -0800
Subject: [PATCH] Broaden the test for AI_NUMERICSERV.

OS X 10.5.8 does not define AI_NUMIERCSERV either, so instead of
 trying to enumerate the platforms that don't, just test for the
 value itself.
Patch by Dave Evans at MacPorts.

Fixes #2172
---
 src/http.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/http.c b/src/http.c
index 4a9eaf5..49cb272 100644
--- a/src/http.c
+++ b/src/http.c
@@ -721,7 +721,7 @@ static struct addrinfo *op_resolve(const char *_host,unsigned _port){
   char             service[6];
   memset(&hints,0,sizeof(hints));
   hints.ai_socktype=SOCK_STREAM;
-#if !defined(_WIN32)
+#if defined(AI_NUMERICSERV)
   hints.ai_flags=AI_NUMERICSERV;
 #endif
   OP_ASSERT(_port<=65535U);
-- 
GitLab