Commit 08af8bf5 authored by Bob Halley's avatar Bob Halley
Browse files

conform to dns_db_addrdataset() API change

parent d127026e
......@@ -364,7 +364,7 @@ signset(dns_db_t *db, dns_dbversion_t *version, dns_dbnode_t *node,
result = dns_rdatalist_tordataset(&siglist, &sigset);
check_result(result, "dns_rdatalist_tordataset");
result = dns_db_addrdataset(db, node, version, 0, &sigset,
ISC_FALSE, NULL);
0, NULL);
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
check_result(result, "dns_db_addrdataset");
......
......@@ -1049,7 +1049,7 @@ t_dns_db_newversion(char **av) {
}
dns_result = dns_db_addrdataset(db, nodep, nversionp, 0,
&added_rdataset, ISC_FALSE, NULL);
&added_rdataset, 0, NULL);
if (dns_result != DNS_R_SUCCESS) {
t_info("dns_db_addrdataset failed %s\n",
dns_result_totext(dns_result));
......@@ -1384,7 +1384,7 @@ t_dns_db_closeversion_1(char **av) {
}
dns_result = dns_db_addrdataset(db, nodep, nversionp, 0,
&added_rdataset, ISC_FALSE, NULL);
&added_rdataset, 0, NULL);
if (dns_result != DNS_R_SUCCESS) {
t_info("dns_db_addrdataset failed %s\n",
dns_result_totext(dns_result));
......@@ -1738,7 +1738,7 @@ t_dns_db_closeversion_2(char **av) {
}
dns_result = dns_db_addrdataset(db, nodep, nversionp, 0,
&added_rdataset, ISC_FALSE, NULL);
&added_rdataset, 0, NULL);
if (dns_result != DNS_R_SUCCESS) {
t_info("dns_db_addrdataset failed %s\n",
dns_result_totext(dns_result));
......
......@@ -381,6 +381,7 @@ main(int argc, char *argv[]) {
dns_name_t *origin;
size_t memory_quota = 0;
dns_trust_t trust = 0;
unsigned int addopts;
dns_result_register();
......@@ -849,10 +850,13 @@ main(int argc, char *argv[]) {
if (dbi != NULL && addmode && !found_as) {
rdataset.ttl++;
rdataset.trust = trust;
if (dns_db_iszone(db))
addopts = DNS_DBADD_MERGE;
else
addopts = 0;
result = dns_db_addrdataset(db, node, version,
0, &rdataset,
dns_db_iszone(db),
NULL);
addopts, NULL);
if (result != DNS_R_SUCCESS)
print_result("", result);
if (printnode)
......
......@@ -364,7 +364,7 @@ signset(dns_db_t *db, dns_dbversion_t *version, dns_dbnode_t *node,
result = dns_rdatalist_tordataset(&siglist, &sigset);
check_result(result, "dns_rdatalist_tordataset");
result = dns_db_addrdataset(db, node, version, 0, &sigset,
ISC_FALSE, NULL);
0, NULL);
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
check_result(result, "dns_db_addrdataset");
......
......@@ -436,7 +436,8 @@ dns_diff_apply(dns_diff_t *diff, dns_db_t *db, dns_dbversion_t *ver)
if (op == DNS_DIFFOP_ADD) {
result = dns_db_addrdataset(db, node, ver,
0, &rds,
ISC_TRUE, NULL);
DNS_DBADD_MERGE,
NULL);
} else if (op == DNS_DIFFOP_DEL) {
result = dns_db_subtractrdataset(db, node, ver,
&rds,
......
......@@ -247,7 +247,7 @@ dns_ncache_add(dns_message_t *message, dns_db_t *cache, dns_dbnode_t *node,
ncrdataset.trust = trust;
return (dns_db_addrdataset(cache, node, NULL, now, &ncrdataset,
ISC_FALSE, addedrdataset));
0, addedrdataset));
}
isc_result_t
......
......@@ -155,7 +155,7 @@ dns_buildnxt(dns_db_t *db, dns_dbversion_t *version, dns_dbnode_t *node,
result = dns_rdatalist_tordataset(&rdatalist, &rdataset);
check_result(result, "dns_rdatalist_tordataset");
result = dns_db_addrdataset(db, node, version, 0, &rdataset,
ISC_FALSE, NULL);
0, NULL);
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
check_result(result, "dns_db_addrdataset");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment