mirror of
https://github.com/freebsd/freebsd-src
synced 2024-07-23 19:28:36 +00:00
pfctl: use pfctl_add_rule_h() rather than pfctl_add_rule()
This ensures we use the handle opened with pfctl_open(), and also brings us closer to the ideal state where everything uses the handle rather than a file descriptor.
This commit is contained in:
parent
0e03402139
commit
76bc4a776f
|
@ -2035,7 +2035,7 @@ pfctl_load_rule(struct pfctl *pf, char *path, struct pfctl_rule *r, int depth)
|
||||||
if ((pf->opts & PF_OPT_NOACTION) == 0) {
|
if ((pf->opts & PF_OPT_NOACTION) == 0) {
|
||||||
if (pfctl_add_pool(pf, &r->rpool, r->af))
|
if (pfctl_add_pool(pf, &r->rpool, r->af))
|
||||||
return (1);
|
return (1);
|
||||||
error = pfctl_add_rule(pf->dev, r, anchor, name, ticket,
|
error = pfctl_add_rule_h(pf->h, r, anchor, name, ticket,
|
||||||
pf->paddr.ticket);
|
pf->paddr.ticket);
|
||||||
switch (error) {
|
switch (error) {
|
||||||
case 0:
|
case 0:
|
||||||
|
|
Loading…
Reference in a new issue