| *** ip_output.c.orig Tue Mar 19 16:19:33 1996 |
| --- ip_output.c Fri Mar 8 14:50:51 1996 |
| *************** |
| *** 60,65 **** |
| --- 60,69 ---- |
| static struct mbuf *ip_insertoptions __P((struct mbuf *, struct mbuf *, int *)); |
| static void ip_mloopback |
| __P((struct ifnet *, struct mbuf *, struct sockaddr_in *)); |
| + #if defined(IPFILTER) |
| + extern int fr_check __P((struct ip *, int, struct ifnet *, int, struct mbuf **)); |
| + extern int (*fr_checkp) __P((struct ip *, int, struct ifnet *, int, struct mbuf **)); |
| + #endif |
| |
| /* |
| * IP output. The packet in mbuf chain m contains a skeletal IP |
| *************** |
| *** 276,281 **** |
| --- 280,296 ---- |
| } else |
| m->m_flags &= ~M_BCAST; |
| |
| sendit: |
| + #if defined(IPFILTER) |
| + { |
| + struct mbuf *m1 = m; |
| + /* |
| + * looks like most checking has been done now...do a filter check |
| + */ |
| + if (fr_checkp && ((error = (*fr_checkp)(ip, hlen, ifp, 1, &m1)) || !m1)) |
| + goto done; |
| + ip = mtod(m = m1, struct ip *); |
| + } |
| + #endif |
| /* |
| * If small enough for interface, can just send directly. |