diff --git a/bin/tests/adb_test.c b/bin/tests/adb_test.c index 584a732508..2caf43bf64 100644 --- a/bin/tests/adb_test.c +++ b/bin/tests/adb_test.c @@ -245,7 +245,7 @@ lookup(const char *target) { INSIST(target != NULL); client = new_client(); - isc_buffer_init(&t, target, strlen(target)); + isc_buffer_constinit(&t, target, strlen(target)); isc_buffer_add(&t, strlen(target)); isc_buffer_init(&namebuf, namedata, sizeof(namedata)); dns_name_init(&name, NULL); diff --git a/bin/tests/db_test.c b/bin/tests/db_test.c index 9019ca53fe..d72bf4f313 100644 --- a/bin/tests/db_test.c +++ b/bin/tests/db_test.c @@ -261,7 +261,7 @@ load(const char *filename, const char *origintext, isc_boolean_t cache) { ISC_LINK_INIT(dbi, link); len = strlen(origintext); - isc_buffer_init(&source, origintext, len); + isc_buffer_constinit(&source, origintext, len); isc_buffer_add(&source, len); dns_fixedname_init(&forigin); origin = dns_fixedname_name(&forigin); diff --git a/bin/tests/sig0_test.c b/bin/tests/sig0_test.c index 296356af76..6663879c68 100644 --- a/bin/tests/sig0_test.c +++ b/bin/tests/sig0_test.c @@ -261,7 +261,7 @@ main(int argc, char *argv[]) { dns_fixedname_init(&fname); name = dns_fixedname_name(&fname); - isc_buffer_init(&b, "child.example.", strlen("child.example.")); + isc_buffer_constinit(&b, "child.example.", strlen("child.example.")); isc_buffer_add(&b, strlen("child.example.")); result = dns_name_fromtext(name, &b, dns_rootname, 0, NULL); CHECK("dns_name_fromtext", result); diff --git a/bin/tests/zone_test.c b/bin/tests/zone_test.c index 124d0f5206..714a699680 100644 --- a/bin/tests/zone_test.c +++ b/bin/tests/zone_test.c @@ -100,7 +100,7 @@ setup(const char *zonename, const char *filename, const char *classname) { dns_zone_settype(zone, zonetype); - isc_buffer_init(&buffer, zonename, strlen(zonename)); + isc_buffer_constinit(&buffer, zonename, strlen(zonename)); isc_buffer_add(&buffer, strlen(zonename)); dns_fixedname_init(&fixorigin); result = dns_name_fromtext(dns_fixedname_name(&fixorigin),