about summary refs log tree commit diff
path: root/resolv
diff options
context:
space:
mode:
Diffstat (limited to 'resolv')
-rw-r--r--resolv/gethnamaddr.c3
-rw-r--r--resolv/inet_ntop.c8
-rw-r--r--resolv/inet_pton.c6
-rw-r--r--resolv/netdb.h44
-rw-r--r--resolv/res_init.c3
5 files changed, 36 insertions, 28 deletions
diff --git a/resolv/gethnamaddr.c b/resolv/gethnamaddr.c
index 49aea2a719..5b9950af1f 100644
--- a/resolv/gethnamaddr.c
+++ b/resolv/gethnamaddr.c
@@ -386,9 +386,10 @@ getanswer(answer, anslen, qname, qtype)
 				continue;
 			}
 			if (hap >= &h_addr_ptrs[MAXADDRS-1]) {
-				if (!toobig++)
+				if (!toobig++) {
 					dprintf("Too many addresses (%d)\n",
 						MAXADDRS);
+				}
 				cp += n;
 				continue;
 			}
diff --git a/resolv/inet_ntop.c b/resolv/inet_ntop.c
index bbdabd0fe0..644abee4a7 100644
--- a/resolv/inet_ntop.c
+++ b/resolv/inet_ntop.c
@@ -40,8 +40,10 @@ static char rcsid[] = "$Id$";
  * sizeof(int) < 4.  sizeof(int) > 4 is fine; all the world's not a VAX.
  */
 
-static const char *inet_ntop4 __P((const u_char *src, char *dst, size_t size));
-static const char *inet_ntop6 __P((const u_char *src, char *dst, size_t size));
+static const char *inet_ntop4 __P((const u_char *src, char *dst, size_t size))
+     internal_function;
+static const char *inet_ntop6 __P((const u_char *src, char *dst, size_t size))
+     internal_function;
 
 /* char *
  * inet_ntop(af, src, dst, size)
@@ -82,6 +84,7 @@ inet_ntop(af, src, dst, size)
  *	Paul Vixie, 1996.
  */
 static const char *
+internal_function
 inet_ntop4(src, dst, size)
 	const u_char *src;
 	char *dst;
@@ -105,6 +108,7 @@ inet_ntop4(src, dst, size)
  *	Paul Vixie, 1996.
  */
 static const char *
+internal_function
 inet_ntop6(src, dst, size)
 	const u_char *src;
 	char *dst;
diff --git a/resolv/inet_pton.c b/resolv/inet_pton.c
index 3593da262b..0c8f79f2c5 100644
--- a/resolv/inet_pton.c
+++ b/resolv/inet_pton.c
@@ -33,8 +33,8 @@ static char rcsid[] = "$Id$";
  * sizeof(int) < 4.  sizeof(int) > 4 is fine; all the world's not a VAX.
  */
 
-static int	inet_pton4 __P((const char *src, u_char *dst));
-static int	inet_pton6 __P((const char *src, u_char *dst));
+static int inet_pton4 __P((const char *src, u_char *dst)) internal_function;
+static int inet_pton6 __P((const char *src, u_char *dst)) internal_function;
 
 /* int
  * inet_pton(af, src, dst)
@@ -76,6 +76,7 @@ inet_pton(af, src, dst)
  *	Paul Vixie, 1996.
  */
 static int
+internal_function
 inet_pton4(src, dst)
 	const char *src;
 	u_char *dst;
@@ -130,6 +131,7 @@ inet_pton4(src, dst)
  *	Paul Vixie, 1996.
  */
 static int
+internal_function
 inet_pton6(src, dst)
 	const char *src;
 	u_char *dst;
diff --git a/resolv/netdb.h b/resolv/netdb.h
index c59553c7ed..fdfc056750 100644
--- a/resolv/netdb.h
+++ b/resolv/netdb.h
@@ -413,30 +413,30 @@ struct addrinfo
 };
 
 /* Possible values for `ai_flags' field in `addrinfo' structure.  */
-#define	AI_PASSIVE	1	/* Socket address is intended for `bind'.  */
-#define	AI_CANONNAME	2	/* Request for canonical name.  */
+# define AI_PASSIVE	1	/* Socket address is intended for `bind'.  */
+# define AI_CANONNAME	2	/* Request for canonical name.  */
 
 /* Error values for `getaddrinfo' function.  */
-#define	EAI_BADFLAGS	-1	/* Invalid value for `ai_flags' field.  */
-#define	EAI_NONAME	-2	/* NAME or SERVICE is unknown.  */
-#define	EAI_AGAIN	-3	/* Temporary failure in name resolution.  */
-#define	EAI_FAIL	-4	/* Non-recoverable failure in name res.  */
-#define	EAI_NODATA	-5	/* No address associated with NAME.  */
-#define	EAI_FAMILY	-6	/* `ai_family' not supported.  */
-#define	EAI_SOCKTYPE	-7	/* `ai_socktype' not supported.  */
-#define	EAI_SERVICE	-8	/* SERVICE not supported for `ai_socktype'.  */
-#define	EAI_ADDRFAMILY	-9	/* Address family for NAME not supported.  */
-#define	EAI_MEMORY	-10	/* Memory allocation failure.  */
-#define	EAI_SYSTEM	-11	/* System error returned in `errno'.  */
-
-#define NI_MAXHOST      1025
-#define NI_MAXSERV      32
-
-#define NI_NUMERICHOST 1
-#define NI_NUMERICSERV 2
-#define NI_NOFQDN 4
-#define NI_NAMEREQD 8
-#define NI_DGRAM 16
+# define EAI_BADFLAGS	-1	/* Invalid value for `ai_flags' field.  */
+# define EAI_NONAME	-2	/* NAME or SERVICE is unknown.  */
+# define EAI_AGAIN	-3	/* Temporary failure in name resolution.  */
+# define EAI_FAIL	-4	/* Non-recoverable failure in name res.  */
+# define EAI_NODATA	-5	/* No address associated with NAME.  */
+# define EAI_FAMILY	-6	/* `ai_family' not supported.  */
+# define EAI_SOCKTYPE	-7	/* `ai_socktype' not supported.  */
+# define EAI_SERVICE	-8	/* SERVICE not supported for `ai_socktype'.  */
+# define EAI_ADDRFAMILY	-9	/* Address family for NAME not supported.  */
+# define EAI_MEMORY	-10	/* Memory allocation failure.  */
+# define EAI_SYSTEM	-11	/* System error returned in `errno'.  */
+
+# define NI_MAXHOST      1025
+# define NI_MAXSERV      32
+
+# define NI_NUMERICHOST 1
+# define NI_NUMERICSERV 2
+# define NI_NOFQDN 4
+# define NI_NAMEREQD 8
+# define NI_DGRAM 16
 
 /* Translate name of a service location and/or a service name to set of
    socket addresses.  */
diff --git a/resolv/res_init.c b/resolv/res_init.c
index 755b88d466..a2de01f1a2 100644
--- a/resolv/res_init.c
+++ b/resolv/res_init.c
@@ -110,7 +110,7 @@ static int netinfo_res_init __P((int *haveenv, int *havesearch));
 # include "../conf/options.h"
 #endif
 
-static void res_setoptions __P((char *, char *));
+static void res_setoptions __P((char *, char *)) internal_function;
 
 #ifdef RESOLVSORT
 static const char sort_mask[] = "/&";
@@ -428,6 +428,7 @@ res_init()
 }
 
 static void
+internal_function
 res_setoptions(options, source)
 	char *options, *source;
 {