2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-31 14:35:26 +00:00

Refactor dns_{acl,aclenv}_create to return void

The dns_{acl,aclenv}_create() can't fail, so change it to return void.
This commit is contained in:
Ondřej Surý
2023-10-13 08:17:31 +02:00
committed by Ondřej Surý
parent f5b0bd9b1b
commit b3a8f0048f
7 changed files with 33 additions and 116 deletions

View File

@@ -685,10 +685,7 @@ cfg_acl_fromconfig(const cfg_obj_t *acl_data, const cfg_obj_t *cctx,
nelem = cfg_list_length(caml, false);
}
result = dns_acl_create(mctx, nelem, &dacl);
if (result != ISC_R_SUCCESS) {
return (result);
}
dns_acl_create(mctx, nelem, &dacl);
}
if (is_tuple) {
@@ -771,12 +768,8 @@ cfg_acl_fromconfig(const cfg_obj_t *acl_data, const cfg_obj_t *cctx,
iptab = dacl->iptable;
if (nest_level != 0) {
result = dns_acl_create(mctx,
cfg_list_length(ce, false),
&de->nestedacl);
if (result != ISC_R_SUCCESS) {
goto cleanup;
}
dns_acl_create(mctx, cfg_list_length(ce, false),
&de->nestedacl);
iptab = de->nestedacl->iptable;
}