diff options
author | luigi <luigi@FreeBSD.org> | 2002-09-12 01:05:46 +0000 |
---|---|---|
committer | luigi <luigi@FreeBSD.org> | 2002-09-12 01:05:46 +0000 |
commit | 23faaeb316f2c857606ee713dfa149a835aa0500 (patch) | |
tree | 5b8634ff89e9e48a66fd02773188e54618378834 | |
parent | 4eb7324870821ed43689fe000ead5b3815f6e051 (diff) | |
download | FreeBSD-src-23faaeb316f2c857606ee713dfa149a835aa0500.zip FreeBSD-src-23faaeb316f2c857606ee713dfa149a835aa0500.tar.gz |
Make bridging and layer2-ipfw obey net.inet.ip.fw.one_pass.
I should have committed this ages ago.
The MFC for if_ethersubr.c could be done in the usual few days (only
ipfw2 uses it), the one for bridge.c should probably wait until
after 4.7 because it changes an existing though mostly undocumented
behaviour (on which i hope nobody relies). All in all, i'll wait for
both things unless there is demand.
MFC after: 35 days
-rw-r--r-- | sys/net/bridge.c | 4 | ||||
-rw-r--r-- | sys/net/if_ethersubr.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/net/bridge.c b/sys/net/bridge.c index b37ba6c..23736de 100644 --- a/sys/net/bridge.c +++ b/sys/net/bridge.c @@ -863,8 +863,8 @@ bdg_forward(struct mbuf *m0, struct ether_header *const eh, struct ifnet *dst) int i; - if (args.rule != NULL) /* packet already partially processed */ - goto forward; /* HACK! I should obey the fw_one_pass */ + if (args.rule != NULL && fw_one_pass) + goto forward; /* packet already partially processed */ /* * i need some amt of data to be contiguous, and in case others need * the packet (shared==1) also better be in the first mbuf. diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index 18e48a3..8d12628 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -463,8 +463,8 @@ ether_ipfw_chk(struct mbuf **m0, struct ifnet *dst, int i; struct ip_fw_args args; - if (*rule != NULL) /* dummynet packet, already partially processed */ - return 1; /* HACK! I should obey the fw_one_pass */ + if (*rule != NULL && fw_one_pass) + return 1; /* dummynet packet, already partially processed */ /* * I need some amt of data to be contiguous, and in case others need |