aboutsummaryrefslogtreecommitdiff
path: root/ares/ares_getnameinfo.c
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2008-09-17 11:31:37 +0000
committerYang Tse <yangsita@gmail.com>2008-09-17 11:31:37 +0000
commit0c1ae21c110454413f0a19ef8134e024f4c5c6ef (patch)
tree8122f99e8dde163d8bb6b158fa7156cb978c9ed6 /ares/ares_getnameinfo.c
parentf30959c6bd01a90d1f6b17d72d03a415ec83ec99 (diff)
improve detection of getservbyport_r()
Diffstat (limited to 'ares/ares_getnameinfo.c')
-rw-r--r--ares/ares_getnameinfo.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ares/ares_getnameinfo.c b/ares/ares_getnameinfo.c
index 99d3b87d9..7bd4eca8a 100644
--- a/ares/ares_getnameinfo.c
+++ b/ares/ares_getnameinfo.c
@@ -16,6 +16,13 @@
*/
#include "setup.h"
+#ifdef HAVE_GETSERVBYPORT_R
+# if !defined(GETSERVBYPORT_R_ARGS) || \
+ (GETSERVBYPORT_R_ARGS < 4) || (GETSERVBYPORT_R_ARGS > 6)
+# error "you MUST specifiy a valid number of arguments for getservbyport_r"
+# endif
+#endif
+
#ifdef HAVE_SYS_SOCKET_H
# include <sys/socket.h>
#endif