git: 76bc4a776fac - main - pfctl: use pfctl_add_rule_h() rather than pfctl_add_rule()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 26 May 2024 23:27:04 UTC
The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=76bc4a776facc73905eff5f70d52785de2100cac commit 76bc4a776facc73905eff5f70d52785de2100cac Author: Kristof Provost <kp@FreeBSD.org> AuthorDate: 2024-05-26 21:06:12 +0000 Commit: Kristof Provost <kp@FreeBSD.org> CommitDate: 2024-05-26 21:06:43 +0000 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. --- sbin/pfctl/pfctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 19d05c415f02..1843ec5713d6 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -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 (pfctl_add_pool(pf, &r->rpool, r->af)) 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); switch (error) { case 0: