mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-10-14 10:27:12 +08:00
Update to FreeBSD head 2019-09-24
Git mirror commit 6b0307a0a5184339393f555d5d424190d8a8277a.
This commit is contained in:
@@ -2005,6 +2005,7 @@ int
|
||||
pfctl_set_interface_flags(struct pfctl *pf, char *ifname, int flags, int how)
|
||||
{
|
||||
struct pfioc_iface pi;
|
||||
struct node_host *h = NULL, *n = NULL;
|
||||
|
||||
if ((loadopt & PFCTL_FLAG_OPTION) == 0)
|
||||
return (0);
|
||||
@@ -2013,6 +2014,12 @@ pfctl_set_interface_flags(struct pfctl *pf, char *ifname, int flags, int how)
|
||||
|
||||
pi.pfiio_flags = flags;
|
||||
|
||||
/* Make sure our cache matches the kernel. If we set or clear the flag
|
||||
* for a group this applies to all members. */
|
||||
h = ifa_grouplookup(ifname, 0);
|
||||
for (n = h; n != NULL; n = n->next)
|
||||
pfctl_set_interface_flags(pf, n->ifname, flags, how);
|
||||
|
||||
if (strlcpy(pi.pfiio_name, ifname, sizeof(pi.pfiio_name)) >=
|
||||
sizeof(pi.pfiio_name))
|
||||
errx(1, "pfctl_set_interface_flags: strlcpy");
|
||||
|
Reference in New Issue
Block a user