aboutsummaryrefslogtreecommitdiff
path: root/sys/net/if_bridge.c
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2020-01-01 17:31:43 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2020-01-01 17:31:43 +0000
commit8d5c56dab1ae14d490b1783ba1816f4e1a839372 (patch)
treee3cf15463d5fcce1598c08b45cd0f7dda95e8e09 /sys/net/if_bridge.c
parentd3eae2a68ebac3d69e049ba2fed3609433d8cb12 (diff)
downloadsrc-8d5c56dab1ae14d490b1783ba1816f4e1a839372.tar.gz
src-8d5c56dab1ae14d490b1783ba1816f4e1a839372.zip
In r343631 error code for a packet blocked by a firewall was
changed from EACCES to EPERM. This change was not intentional, so fix that. Return EACCESS if a firewall forbids sending. Noticed by: ae
Notes
Notes: svn path=/head/; revision=356252
Diffstat (limited to 'sys/net/if_bridge.c')
-rw-r--r--sys/net/if_bridge.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/net/if_bridge.c b/sys/net/if_bridge.c
index 3a5e1f3d8968..f884c039b529 100644
--- a/sys/net/if_bridge.c
+++ b/sys/net/if_bridge.c
@@ -3191,7 +3191,7 @@ bridge_pfil(struct mbuf **mp, struct ifnet *bifp, struct ifnet *ifp, int dir)
dir == PFIL_OUT && ifp != NULL) {
switch (pfil_run_hooks(V_link_pfil_head, mp, ifp, dir, NULL)) {
case PFIL_DROPPED:
- return (EPERM);
+ return (EACCES);
case PFIL_CONSUMED:
return (0);
}
@@ -3312,7 +3312,7 @@ bridge_pfil(struct mbuf **mp, struct ifnet *bifp, struct ifnet *ifp, int dir)
case PFIL_CONSUMED:
return (0);
case PFIL_DROPPED:
- return (EPERM);
+ return (EACCES);
default:
break;
}