aboutsummaryrefslogtreecommitdiffstats
path: root/inet_ntop.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>1999-10-14 06:55:11 +0000
committerGuy Harris <guy@alum.mit.edu>1999-10-14 06:55:11 +0000
commitae276ffe2010027af678da5453339affcdde66be (patch)
tree09b20a56b5d5081b22bafd4a31a690a2a3bd22ec /inet_ntop.c
parent831497b33e358305b8f409882ec61097335b772d (diff)
Make it build on systems lacking "inet_pton()", "inet_ntop()", and a
definition of "AF_INET6". Declare those functions and, if it's not defined, define "AF_INET6" in "inet_v6defs.h", and arrange to include it if "inet_ntop()" is missing. (Systems will probably have both of them or lack both of them, and we may choose not to use the system's "inet_pton()" because it's buggy, so base the decision on whether to include "inet_v6defs.h" on whether we're using the system's "inet_ntop()" or not.) Fix some macro references in "Makefile.am" and "configure.in". svn path=/trunk/; revision=830
Diffstat (limited to 'inet_ntop.c')
-rw-r--r--inet_ntop.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/inet_ntop.c b/inet_ntop.c
index 009ac4e305..ff80e4e1f8 100644
--- a/inet_ntop.c
+++ b/inet_ntop.c
@@ -16,9 +16,11 @@
*/
#if defined(LIBC_SCCS) && !defined(lint)
-static char rcsid[] = "$Id: inet_ntop.c,v 1.1 1999/10/14 05:41:29 itojun Exp $";
+static char rcsid[] = "$Id: inet_ntop.c,v 1.2 1999/10/14 06:55:08 guy Exp $";
#endif /* LIBC_SCCS and not lint */
+#include "config.h"
+
#include <sys/param.h>
#include <sys/types.h>
#include <sys/socket.h>
@@ -40,6 +42,8 @@ static char rcsid[] = "$Id: inet_ntop.c,v 1.1 1999/10/14 05:41:29 itojun Exp $";
# include "snprintf.h"
#endif
+#include "inet_v6defs.h"
+
#ifndef NS_INADDRSZ
#define NS_INADDRSZ 4
#endif