]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
more DNS_OPT_NEWCODES sanitation
authorAndreas Gustafsson <source@isc.org>
Sat, 2 Dec 2000 04:44:51 +0000 (04:44 +0000)
committerAndreas Gustafsson <source@isc.org>
Sat, 2 Dec 2000 04:44:51 +0000 (04:44 +0000)
bin/dig/dighost.c
bin/named/query.c
lib/dns/message.c

index 42be9ee4d1bc2a651fbbd7ec8ac6ec1801183ab5..22c8631a567dc2f91c2bd0803cc8f9f94779f9f9 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: dighost.c,v 1.166 2000/11/21 21:35:32 mws Exp $ */
+/* $Id: dighost.c,v 1.167 2000/12/02 04:44:51 gson Exp $ */
 
 /*
  * Notice to programmers:  Do not use this code as an example of how to
@@ -40,7 +40,9 @@ extern int h_errno;
 #include <dns/fixedname.h>
 #include <dns/message.h>
 #include <dns/name.h>
+#ifdef DNS_OPT_NEWCODES
 #include <dns/opt.h>
+#endif /* DNS_OPT_NEWCODES */
 #include <dns/rdata.h>
 #include <dns/rdataclass.h>
 #include <dns/rdatalist.h>
index f6884180df1699efaf2e30af66bdac36a81e0086..8244f4923f9d12ecdd8bc44898ed40958f9a513c 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: query.c,v 1.157 2000/12/01 23:49:47 gson Exp $ */
+/* $Id: query.c,v 1.158 2000/12/02 04:43:21 gson Exp $ */
 
 #include <config.h>
 
@@ -27,7 +27,9 @@
 #include <dns/db.h>
 #include <dns/events.h>
 #include <dns/message.h>
+#ifdef DNS_OPT_NEWCODES
 #include <dns/opt.h>
+#endif /* DNS_OPT_NEWCODES */
 #include <dns/rdata.h>
 #include <dns/rdataclass.h>
 #include <dns/rdatalist.h>
index f2b2856876f312e1faf97ff63a1be1346154c687..835a07d24a6ffe20f1bc6fef1470535b3705e6ed 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: message.c,v 1.161 2000/12/02 04:24:26 gson Exp $ */
+/* $Id: message.c,v 1.162 2000/12/02 04:41:27 gson Exp $ */
 
 /***
  *** Imports
@@ -2805,6 +2805,9 @@ dns_message_pseudosectiontotext(dns_message_t *msg,
        isc_result_t result;
        isc_boolean_t omit_final_dot;
 
+#ifdef DNS_OPT_NEWCODES
+       char buf[sizeof("1234567890")];
+#endif /* DNS_OPT_NEWCODES */
        REQUIRE(DNS_MESSAGE_VALID(msg));
        REQUIRE(target != NULL);
        REQUIRE(VALID_PSEUDOSECTION(section));
@@ -2819,7 +2822,6 @@ dns_message_pseudosectiontotext(dns_message_t *msg,
 #ifdef DNS_OPT_NEWCODES
                result = dns_opt_totext(ps, target, flags);
 #else /* DNS_OPT_NEWCODES */
-               result = dns_opt_totext(ps, target, flags);
                if ((flags & DNS_MESSAGETEXTFLAG_NOCOMMENTS) == 0)
                        ADD_STRING(target, ";; OPT PSEUDOSECTION:\n");
                ADD_STRING(target, "; EDNS: version: ");