mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-27 12:13:20 -04:00
Extract empty name in 'source' into 'name'
(cherry picked from commit e6984e5c07)
This commit is contained in:
parent
26b522b54d
commit
5901065534
1 changed files with 12 additions and 0 deletions
|
|
@ -321,6 +321,18 @@ ISC_RUN_TEST_IMPL(fromregion) {
|
|||
assert_int_equal(8, name.length);
|
||||
assert_ptr_equal(source, name.ndata);
|
||||
assert_false(dns_name_isabsolute(&name));
|
||||
|
||||
/*
|
||||
* Extract empty name in 'source' into 'name'.
|
||||
*/
|
||||
isc_buffer_init(&b, target, sizeof(target));
|
||||
dns_name_init(&name, NULL);
|
||||
r.base = source;
|
||||
r.length = 0;
|
||||
dns_name_fromregion(&name, &r);
|
||||
assert_int_equal(0, name.length);
|
||||
assert_ptr_equal(source, name.ndata);
|
||||
assert_false(dns_name_isabsolute(&name));
|
||||
}
|
||||
|
||||
/* is trust-anchor-telemetry test */
|
||||
|
|
|
|||
Loading…
Reference in a new issue