mirror of
https://github.com/isc-projects/bind9.git
synced 2026-03-06 15:30:29 -05:00
fix the use of dns_wildcardname as an optimisation in DLZ
(cherry picked from commit cb32cd98bd)
This commit is contained in:
parent
ad39501b0c
commit
09ce08a85f
1 changed files with 8 additions and 5 deletions
|
|
@ -621,17 +621,20 @@ getnodedata(dns_db_t *db, dns_name_t *name, bool create,
|
|||
dns_name_t *wild;
|
||||
|
||||
dns_fixedname_init(&fixed);
|
||||
if (i == dlabels)
|
||||
if (i == dlabels - 1) {
|
||||
wild = dns_wildcardname;
|
||||
else {
|
||||
wild = dns_fixedname_name(&fixed);
|
||||
} else {
|
||||
dns_name_t *fname;
|
||||
fname = dns_fixedname_name(&fixed);
|
||||
dns_name_getlabelsequence(name, i + 1,
|
||||
dlabels - i - 1,
|
||||
wild);
|
||||
fname);
|
||||
result = dns_name_concatenate(dns_wildcardname,
|
||||
wild, wild, NULL);
|
||||
fname, fname,
|
||||
NULL);
|
||||
if (result != ISC_R_SUCCESS)
|
||||
return (result);
|
||||
wild = fname;
|
||||
}
|
||||
|
||||
isc_buffer_init(&b, wildstr, sizeof(wildstr));
|
||||
|
|
|
|||
Loading…
Reference in a new issue