916. [bug] Specifying type ixfr to dig without specifying

a serial number failed in unexpected ways.
This commit is contained in:
Brian Wellington
2001-06-29 06:06:02 +00:00
parent a26ad011f3
commit fed846067d
2 changed files with 19 additions and 1 deletions
+3
View File
@@ -1,4 +1,7 @@
916. [bug] Specifying type ixfr to dig without specifying
a serial number failed in unexpected ways.
915. [func] The named-checkconf and named-checkzone programs
now have a '-v' option for printing their version.
[RT #1151]
+16 -1
View File
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dig.c,v 1.146 2001/06/11 18:08:15 gson Exp $ */
/* $Id: dig.c,v 1.147 2001/06/29 06:06:00 bwelling Exp $ */
#include <config.h>
#include <stdlib.h>
@@ -38,6 +38,7 @@
#include <dns/rdataset.h>
#include <dns/rdatatype.h>
#include <dns/rdataclass.h>
#include <dns/result.h>
#include <dig/dig.h>
@@ -1001,6 +1002,11 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
tr.length = strlen(value);
result = dns_rdatatype_fromtext(&rdtype,
(isc_textregion_t *)&tr);
if (result == ISC_R_SUCCESS &&
rdtype == dns_rdatatype_ixfr)
{
result = DNS_R_UNKNOWN;
}
}
if (result == ISC_R_SUCCESS) {
if ((*lookup)->rdtypeset) {
@@ -1218,6 +1224,15 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
tr.length = strlen(rv[0]);
result = dns_rdatatype_fromtext(&rdtype,
(isc_textregion_t *)&tr);
if (result == ISC_R_SUCCESS &&
rdtype == dns_rdatatype_ixfr)
{
result = DNS_R_UNKNOWN;
fprintf(stderr, ";; Warning, "
"ixfr requires a "
"serial number\n");
continue;
}
}
if (result == ISC_R_SUCCESS)
{