Define AI_ADDRCONFIG in inet.h, needed by OpenBSD

This commit is contained in:
Connor Cooper 2014-01-04 16:56:08 -05:00 committed by TingPing
parent 1e1ef1c6cf
commit 9cba22c38a
1 changed files with 4 additions and 0 deletions

View File

@ -34,6 +34,10 @@
#endif #endif
#ifdef WANTDNS #ifdef WANTDNS
#include <netdb.h> #include <netdb.h>
/* OpenBSD's netdb.h does not define AI_ADDRCONFIG */
#ifndef AI_ADDRCONFIG
#define AI_ADDRCONFIG 0
#endif
#endif #endif
#define closesocket close #define closesocket close
#define set_blocking(sok) fcntl(sok, F_SETFL, 0) #define set_blocking(sok) fcntl(sok, F_SETFL, 0)