diff options
Diffstat (limited to 'lib/libc/resolv/res_init.c')
-rw-r--r-- | lib/libc/resolv/res_init.c | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/lib/libc/resolv/res_init.c b/lib/libc/resolv/res_init.c index f8e4c67..9cb6809 100644 --- a/lib/libc/resolv/res_init.c +++ b/lib/libc/resolv/res_init.c @@ -66,7 +66,7 @@ #if defined(LIBC_SCCS) && !defined(lint) static const char sccsid[] = "@(#)res_init.c 8.1 (Berkeley) 6/7/93"; -static const char rcsid[] = "$Id: res_init.c,v 1.9.2.5.4.6 2006/08/30 23:23:01 marka Exp $"; +static const char rcsid[] = "$Id: res_init.c,v 1.16.18.5 2006/08/30 23:23:13 marka Exp $"; #endif /* LIBC_SCCS and not lint */ #include <sys/cdefs.h> __FBSDID("$FreeBSD$"); @@ -100,7 +100,7 @@ __FBSDID("$FreeBSD$"); #include "res_private.h" -/* Options. Should all be left alone. */ +/*% Options. Should all be left alone. */ #define RESOLVSORT #define DEBUG @@ -116,7 +116,7 @@ static const char sort_mask[] = "/&"; static u_int32_t net_mask(struct in_addr); #endif -#if !defined(isascii) /* XXX - could be a function */ +#if !defined(isascii) /*%< XXX - could be a function */ # define isascii(c) (!(c & 0200)) #endif @@ -124,7 +124,7 @@ static u_int32_t net_mask(struct in_addr); * Resolver state default settings. */ -/* +/*% * Set up default settings. If the configuration file exist, the values * there will have precedence. Otherwise, the server address is set to * INADDR_ANY and the default domain name comes from the gethostname(). @@ -152,14 +152,14 @@ res_ninit(res_state statp) { return (__res_vinit(statp, 0)); } -/* This function has to be reachable by res_data.c but not publically. */ +/*% This function has to be reachable by res_data.c but not publically. */ int __res_vinit(res_state statp, int preinit) { FILE *fp; char *cp, **pp; int n; char buf[BUFSIZ]; - int nserv = 0; /* number of nameserver records read from file */ + int nserv = 0; /*%< number of nameserver records read from file */ int haveenv = 0; int havesearch = 0; #ifdef RESOLVSORT @@ -264,7 +264,7 @@ __res_vinit(res_state statp, int preinit) { pp = statp->dnsrch; *pp++ = cp; for (n = 0; *cp && pp < statp->dnsrch + MAXDNSRCH; cp++) { - if (*cp == '\n') /* silly backwards compat */ + if (*cp == '\n') /*%< silly backwards compat */ break; else if (*cp == ' ' || *cp == '\t') { *cp = 0; @@ -296,7 +296,7 @@ __res_vinit(res_state statp, int preinit) { continue; /* read default domain name */ if (MATCH(buf, "domain")) { - if (haveenv) /* skip if have from environ */ + if (haveenv) /*%< skip if have from environ */ continue; cp = buf + sizeof("domain") - 1; while (*cp == ' ' || *cp == '\t') @@ -312,7 +312,7 @@ __res_vinit(res_state statp, int preinit) { } /* set search list */ if (MATCH(buf, "search")) { - if (haveenv) /* skip if have from environ */ + if (haveenv) /*%< skip if have from environ */ continue; cp = buf + sizeof("search") - 1; while (*cp == ' ' || *cp == '\t') @@ -521,7 +521,7 @@ __res_vinit(res_state statp, int preinit) { while (pp < statp->dnsrch + MAXDFLSRCH) { if (dots < LOCALDOMAINPARTS) break; - cp = strchr(cp, '.') + 1; /* we know there is one */ + cp = strchr(cp, '.') + 1; /*%< we know there is one */ *pp++ = cp; dots--; } @@ -695,7 +695,7 @@ res_setoptions(res_state statp, const char *options, const char *source) #ifdef RESOLVSORT /* XXX - should really support CIDR which means explicit masks always. */ static u_int32_t -net_mask(in) /* XXX - should really use system's version of this */ +net_mask(in) /*!< XXX - should really use system's version of this */ struct in_addr in; { u_int32_t i = ntohl(in.s_addr); @@ -716,7 +716,7 @@ res_randomid(void) { return (0xffff & (now.tv_sec ^ now.tv_usec ^ getpid())); } -/* +/*% * This routine is for closing the socket if a virtual circuit is used and * the program wants to close it. This provides support for endhostent() * which expects to close the socket. @@ -861,3 +861,5 @@ res_getservers(res_state statp, union res_sockaddr_union *set, int cnt) { } return (statp->nscount); } + +/*! \file */ |