From: Ted Lemon Date: Wed, 2 Feb 2000 19:59:16 +0000 (+0000) Subject: Include nameser.h after minires.h X-Git-Tag: V3-BETA-2-PATCH-1~349 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=439a9b002ec6979321047882c739f38d07c1999a;p=thirdparty%2Fdhcp.git Include nameser.h after minires.h --- diff --git a/minires/Makefile.dist b/minires/Makefile.dist index cb9a9e4e6..13705547e 100644 --- a/minires/Makefile.dist +++ b/minires/Makefile.dist @@ -43,10 +43,10 @@ depend: makedepend $(INCLUDES) $(PREDEFINES) $(SRCS) clean: - -rm -f $(OBJ) test.o test cltest.o cltest + -rm -f $(OBJ) libres.a realclean: clean - -rm -f libdhcpctl.a *~ $(CATMANPAGES) $(SEDMANPAGES) + -rm -f *~ $(CATMANPAGES) $(SEDMANPAGES) distclean: realclean -rm -f Makefile diff --git a/minires/base64.c b/minires/base64.c index 0d4b71ac1..65ea65d5c 100644 --- a/minires/base64.c +++ b/minires/base64.c @@ -41,7 +41,7 @@ */ #if !defined(LINT) && !defined(CODECENTER) -static const char rcsid[] = "$Id: base64.c,v 1.1 2000/02/02 07:28:14 mellon Exp $"; +static const char rcsid[] = "$Id: base64.c,v 1.2 2000/02/02 19:59:15 mellon Exp $"; #endif /* not lint */ #include @@ -58,8 +58,8 @@ static const char rcsid[] = "$Id: base64.c,v 1.1 2000/02/02 07:28:14 mellon Exp #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" #define Assert(Cond) if (!(Cond)) abort() diff --git a/minires/dst_api.c b/minires/dst_api.c index 0d1e4f7c7..15e3ab55a 100644 --- a/minires/dst_api.c +++ b/minires/dst_api.c @@ -1,5 +1,5 @@ #ifndef LINT -static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/dst_api.c,v 1.1 2000/02/02 07:28:14 mellon Exp $"; +static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/dst_api.c,v 1.2 2000/02/02 19:59:15 mellon Exp $"; #endif /* @@ -52,8 +52,9 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/dst_api.c, #include #include #include -#include "arpa/nameser.h" + #include "minires/minires.h" +#include "arpa/nameser.h" #include "dst_internal.h" diff --git a/minires/dst_internal.h b/minires/dst_internal.h index d173bc0c0..69654a89a 100644 --- a/minires/dst_internal.h +++ b/minires/dst_internal.h @@ -19,11 +19,6 @@ */ #include #include -#if (!defined(BSD)) || (BSD < 199306) -# include -#else -# include -#endif #ifndef PATH_MAX # ifdef POSIX_PATH_MAX @@ -38,8 +33,8 @@ typedef struct dst_key { int dk_key_size; /* this is the size of the key in bits */ int dk_proto; /* what protocols this key can be used for */ int dk_alg; /* algorithm number from key record */ - u_int32_t dk_flags; /* and the flags of the public key */ - u_int16_t dk_id; /* identifier of the key */ + unsigned dk_flags; /* and the flags of the public key */ + unsigned dk_id; /* identifier of the key */ void *dk_KEY_struct; /* pointer to key in crypto pkg fmt */ struct dst_func *dk_func; /* point to cryptto pgk specific function table */ } DST_KEY; diff --git a/minires/hmac_link.c b/minires/hmac_link.c index f4d20938c..e37c0b45d 100644 --- a/minires/hmac_link.c +++ b/minires/hmac_link.c @@ -1,6 +1,6 @@ #ifdef HMAC_MD5 #ifndef LINT -static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/hmac_link.c,v 1.2 2000/02/02 07:37:19 mellon Exp $"; +static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/hmac_link.c,v 1.3 2000/02/02 19:59:15 mellon Exp $"; #endif /* * Portions Copyright (c) 1995-1998 by Trusted Information Systems, Inc. @@ -33,8 +33,8 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/hmac_link. #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" #include "dst_internal.h" diff --git a/minires/ns_samedomain.c b/minires/ns_samedomain.c index 54f2abd97..cc689a361 100644 --- a/minires/ns_samedomain.c +++ b/minires/ns_samedomain.c @@ -16,7 +16,7 @@ */ #ifndef lint -static const char rcsid[] = "$Id: ns_samedomain.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: ns_samedomain.c,v 1.2 2000/02/02 19:59:15 mellon Exp $"; #endif #include @@ -126,12 +126,12 @@ ns_samedomain(const char *a, const char *b) { */ escaped = 0; for (i = diff - 2; i >= 0; i--) - if (a[i] == '\\') + if (a[i] == '\\') { if (escaped) escaped = 0; else escaped = 1; - else + } else break; if (escaped) return (0); diff --git a/minires/ns_sign.c b/minires/ns_sign.c index 54ffffa99..60d9693df 100644 --- a/minires/ns_sign.c +++ b/minires/ns_sign.c @@ -16,7 +16,7 @@ */ #ifndef lint -static const char rcsid[] = "$Id: ns_sign.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: ns_sign.c,v 1.2 2000/02/02 19:59:15 mellon Exp $"; #endif /* Import. */ @@ -36,11 +36,11 @@ static const char rcsid[] = "$Id: ns_sign.c,v 1.1 2000/02/02 07:28:15 mellon Exp #include #include -#include - #include "minires/minires.h" #include "arpa/nameser.h" +#include + #define BOUNDS_CHECK(ptr, count) \ do { \ if ((ptr) + (count) > eob) { \ diff --git a/minires/ns_verify.c b/minires/ns_verify.c index 9eaf225b2..31bbc5b79 100644 --- a/minires/ns_verify.c +++ b/minires/ns_verify.c @@ -16,7 +16,7 @@ */ #ifndef lint -static const char rcsid[] = "$Id: ns_verify.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: ns_verify.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* Import. */ @@ -36,9 +36,9 @@ static const char rcsid[] = "$Id: ns_verify.c,v 1.1 2000/02/02 07:28:15 mellon E #include #include -#include #include "minires/minires.h" #include "arpa/nameser.h" +#include /* Private. */ diff --git a/minires/prandom.c b/minires/prandom.c index 9421f9e29..b35810864 100644 --- a/minires/prandom.c +++ b/minires/prandom.c @@ -1,5 +1,5 @@ #ifndef LINT -static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/prandom.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/prandom.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* * Portions Copyright (c) 1995-1998 by Trusted Information Systems, Inc. @@ -30,14 +30,13 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/prandom.c, #include #include -#include "dst_internal.h" - #include #include -#include "arpa/nameser.h" #define NEED_PRAND_CONF #include "minires/minires.h" -/* XXX #include "prand_conf.h" XXX */ +#include "dst_internal.h" +#include "arpa/nameser.h" + #ifndef DST_NUM_HASHES #define DST_NUM_HASHES 4 diff --git a/minires/res_comp.c b/minires/res_comp.c index 1f0a5be92..4ca538e5d 100644 --- a/minires/res_comp.c +++ b/minires/res_comp.c @@ -70,7 +70,7 @@ #if defined(LIBC_SCCS) && !defined(lint) static const char sccsid[] = "@(#)res_comp.c 8.1 (Berkeley) 6/4/93"; -static const char rcsid[] = "$Id: res_comp.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_comp.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -82,8 +82,8 @@ static const char rcsid[] = "$Id: res_comp.c,v 1.1 2000/02/02 07:28:15 mellon Ex #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" /* * Expand compressed domain name 'comp_dn' to full domain name. diff --git a/minires/res_findzonecut.c b/minires/res_findzonecut.c index 61ef488c1..44ef49013 100644 --- a/minires/res_findzonecut.c +++ b/minires/res_findzonecut.c @@ -1,5 +1,5 @@ #if !defined(lint) && !defined(SABER) -static const char rcsid[] = "$Id: res_findzonecut.c,v 1.2 2000/02/02 08:21:08 mellon Exp $"; +static const char rcsid[] = "$Id: res_findzonecut.c,v 1.3 2000/02/02 19:59:16 mellon Exp $"; #endif /* not lint */ /* @@ -38,8 +38,8 @@ static const char rcsid[] = "$Id: res_findzonecut.c,v 1.2 2000/02/02 08:21:08 me #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" /* Data structures. */ diff --git a/minires/res_init.c b/minires/res_init.c index 89671b8cb..c77796067 100644 --- a/minires/res_init.c +++ b/minires/res_init.c @@ -70,7 +70,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.2 2000/02/02 07:37:19 mellon Exp $"; +static const char rcsid[] = "$Id: res_init.c,v 1.3 2000/02/02 19:59:16 mellon Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -87,8 +87,8 @@ static const char rcsid[] = "$Id: res_init.c,v 1.2 2000/02/02 07:37:19 mellon Ex #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" /* Options. Should all be left alone. */ #define RESOLVSORT diff --git a/minires/res_mkquery.c b/minires/res_mkquery.c index 77ed8903f..ef837c9e1 100644 --- a/minires/res_mkquery.c +++ b/minires/res_mkquery.c @@ -70,7 +70,7 @@ #if defined(LIBC_SCCS) && !defined(lint) static const char sccsid[] = "@(#)res_mkquery.c 8.1 (Berkeley) 6/4/93"; -static const char rcsid[] = "$Id: res_mkquery.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_mkquery.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -94,7 +94,7 @@ int res_nmkquery(res_state statp, int op, /* opcode of query */ const char *dname, /* domain name */ - ns_class class, ns_class type, /* class and type of query */ + ns_class class, ns_type type, /* class and type of query */ const u_char *data, /* resource record data */ unsigned datalen, /* length of data */ const u_char *newrr_in, /* new rr for modify or append */ diff --git a/minires/res_mkupdate.c b/minires/res_mkupdate.c index 3f78e2aa8..b1d38d7da 100644 --- a/minires/res_mkupdate.c +++ b/minires/res_mkupdate.c @@ -21,14 +21,13 @@ */ #if !defined(lint) && !defined(SABER) -static const char rcsid[] = "$Id: res_mkupdate.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_mkupdate.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* not lint */ #include #include #include -#include "arpa/nameser.h" #include #include @@ -42,6 +41,7 @@ static const char rcsid[] = "$Id: res_mkupdate.c,v 1.1 2000/02/02 07:28:15 mello #include #include "minires/minires.h" +#include "arpa/nameser.h" /* Options. Leave them on. */ #define DEBUG @@ -93,7 +93,6 @@ res_nmkupdate(res_state statp, unsigned n; ns_updrec *rrecp; struct in_addr ina; - struct in6_addr in6a; char buf2[MAXDNAME]; u_char buf3[MAXDNAME]; int section, numrrs = 0, counts[ns_s_max]; diff --git a/minires/res_query.c b/minires/res_query.c index 97a229a66..f9bcc40b6 100644 --- a/minires/res_query.c +++ b/minires/res_query.c @@ -70,7 +70,7 @@ #if defined(LIBC_SCCS) && !defined(lint) static const char sccsid[] = "@(#)res_query.c 8.1 (Berkeley) 6/4/93"; -static const char rcsid[] = "$Id: res_query.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_query.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -85,8 +85,8 @@ static const char rcsid[] = "$Id: res_query.c,v 1.1 2000/02/02 07:28:15 mellon E #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" /* Options. Leave them on. */ #define DEBUG @@ -317,7 +317,7 @@ int res_nquerydomain(res_state statp, const char *name, const char *domain, - ns_class class, ns_class type, + ns_class class, ns_type type, u_char *answer, unsigned anslen) { diff --git a/minires/res_send.c b/minires/res_send.c index b6c6c2244..7f3411137 100644 --- a/minires/res_send.c +++ b/minires/res_send.c @@ -70,7 +70,7 @@ #if defined(LIBC_SCCS) && !defined(lint) static const char sccsid[] = "@(#)res_send.c 8.1 (Berkeley) 6/4/93"; -static const char rcsid[] = "$Id: res_send.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_send.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* LIBC_SCCS and not lint */ /* @@ -94,8 +94,8 @@ static const char rcsid[] = "$Id: res_send.c,v 1.1 2000/02/02 07:28:15 mellon Ex #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" #define CHECK_SRVR_ADDR @@ -312,7 +312,7 @@ res_nsend(res_state statp, if (statp->_sock >= 0 && (statp->_flags & RES_F_VC) != 0) { struct sockaddr_in peer; - int size = sizeof(peer); + socklen_t size = sizeof(peer); if (getpeername(statp->_sock, (struct sockaddr *)&peer, @@ -478,7 +478,8 @@ res_nsend(res_state statp, int start, timeout, finish; fd_set dsmask; struct sockaddr_in from; - int fromlen, seconds; + socklen_t fromlen; + int seconds; if (statp->_sock < 0 || (statp->_flags & RES_F_VC) != 0) { @@ -557,7 +558,8 @@ res_nsend(res_state statp, sizeof no_addr); #else struct sockaddr_in local_addr; - int len, result, s1; + socklen_t len; + int result, s1; len = sizeof(local_addr); s1 = socket(PF_INET, SOCK_DGRAM, 0); diff --git a/minires/res_sendsigned.c b/minires/res_sendsigned.c index 0931af27e..cc63e4315 100644 --- a/minires/res_sendsigned.c +++ b/minires/res_sendsigned.c @@ -5,8 +5,6 @@ #include #include -#include - #include #include #include @@ -14,8 +12,10 @@ #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" + +#include /* res_nsendsigned */ int diff --git a/minires/res_update.c b/minires/res_update.c index d63e7d3f2..bf7060c94 100644 --- a/minires/res_update.c +++ b/minires/res_update.c @@ -1,5 +1,5 @@ #if !defined(lint) && !defined(SABER) -static const char rcsid[] = "$Id: res_update.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Id: res_update.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; #endif /* not lint */ /* @@ -40,8 +40,8 @@ static const char rcsid[] = "$Id: res_update.c,v 1.1 2000/02/02 07:28:15 mellon #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" /* * Separate a linked list of records into groups so that all records diff --git a/minires/support.c b/minires/support.c index d3fe8d3dd..9b681ab71 100644 --- a/minires/support.c +++ b/minires/support.c @@ -1,4 +1,4 @@ -static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/support.c,v 1.1 2000/02/02 07:28:15 mellon Exp $"; +static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/support.c,v 1.2 2000/02/02 19:59:16 mellon Exp $"; /* @@ -26,8 +26,8 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/minires/Attic/support.c, #include #include #include -#include "arpa/nameser.h" #include "minires/minires.h" +#include "arpa/nameser.h" #include "dst_internal.h" @@ -384,7 +384,7 @@ int dst_s_build_filename(char *filename, const char *name, unsigned id, int alg, const char *suffix, size_t filename_length) { - u_int32_t my_id; + unsigned my_id; if (filename == NULL) return (-1); memset(filename, 0, filename_length);