summaryrefslogtreecommitdiff
path: root/inet_net_pton.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2013-02-17 16:13:39 (GMT)
committerDaniel Stenberg <daniel@haxx.se>2013-02-17 16:44:02 (GMT)
commitcf7ad9758dd7927595cb9751ba8173e06fc33cad (patch)
treed62a9428b21c5d629c66a879ea2849cb2b4f6ee4 /inet_net_pton.c
parentee9a1c2457c3238ee5cdae90fe18440d44377adc (diff)
downloadc-ares-cf7ad9758dd7927595cb9751ba8173e06fc33cad.zip
c-ares-cf7ad9758dd7927595cb9751ba8173e06fc33cad.tar.gz
c-ares-cf7ad9758dd7927595cb9751ba8173e06fc33cad.tar.bz2
ares_inet_pton/ntop: cleanup
Make sure that the symbols are always exported and present in c-ares. Make the headers prefixed with 'ares'. Removed the inet_ntop.h version as it no longer features any content.
Diffstat (limited to 'inet_net_pton.c')
-rw-r--r--inet_net_pton.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/inet_net_pton.c b/inet_net_pton.c
index 8199934..71c07c5 100644
--- a/inet_net_pton.c
+++ b/inet_net_pton.c
@@ -36,7 +36,7 @@
#include "ares.h"
#include "ares_ipv6.h"
#include "ares_nowarn.h"
-#include "inet_net_pton.h"
+#include "ares_inet_net_pton.h"
const struct ares_in6_addr ares_in6addr_any = { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } };
@@ -440,4 +440,11 @@ int ares_inet_pton(int af, const char *src, void *dst)
return 0;
return (result > -1 ? 1 : -1);
}
+#else /* HAVE_INET_PTON */
+int ares_inet_pton(int af, const char *src, void *dst)
+{
+ /* just relay this to the underlying function */
+ return inet_pton(af, src, dst);
+}
+
#endif