[vlc-devel] [PATCH] net: define macros for getaddrinfo() on OS/2

KO Myung-Hun komh78 at gmail.com
Wed Mar 22 13:37:11 CET 2017


This fixes compilation breakage on OS/2 caused by commit
898b9dd532a73344267d65f5edff52697a7dc29c.
---
 include/vlc_network.h | 43 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)

diff --git a/include/vlc_network.h b/include/vlc_network.h
index 6100cc93d0..58955fe7ce 100644
--- a/include/vlc_network.h
+++ b/include/vlc_network.h
@@ -207,6 +207,49 @@ VLC_API int vlc_close(int);
 #endif
 
 #ifdef __OS2__
+/* GAI error codes */
+# ifndef EAI_BADFLAGS
+#  define EAI_BADFLAGS -1
+# endif
+# ifndef EAI_NONAME
+#  define EAI_NONAME -2
+# endif
+# ifndef EAI_AGAIN
+#  define EAI_AGAIN -3
+# endif
+# ifndef EAI_FAIL
+#  define EAI_FAIL -4
+# endif
+# ifndef EAI_NODATA
+#  define EAI_NODATA -5
+# endif
+# ifndef EAI_FAMILY
+#  define EAI_FAMILY -6
+# endif
+# ifndef EAI_SOCKTYPE
+#  define EAI_SOCKTYPE -7
+# endif
+# ifndef EAI_SERVICE
+#  define EAI_SERVICE -8
+# endif
+# ifndef EAI_ADDRFAMILY
+#  define EAI_ADDRFAMILY -9
+# endif
+# ifndef EAI_MEMORY
+#  define EAI_MEMORY -10
+# endif
+# ifndef EAI_OVERFLOW
+#  define EAI_OVERFLOW -11
+# endif
+# ifndef EAI_SYSTEM
+#  define EAI_SYSTEM -12
+# endif
+
+# ifndef NI_MAXHOST
+#  define NI_MAXHOST 1025
+#  define NI_MAXSERV 32
+# endif
+
 # ifndef NI_NUMERICHOST
 #  define NI_NUMERICHOST 0x01
 #  define NI_NUMERICSERV 0x02
-- 
2.11.0



More information about the vlc-devel mailing list