diff options
-rw-r--r-- | sys/net/bridge.c | 4 | ||||
-rw-r--r-- | sys/netinet/in.h | 5 | ||||
-rw-r--r-- | sys/netinet/ip_dummynet.c | 9 | ||||
-rw-r--r-- | sys/netinet/ip_input.c | 4 | ||||
-rw-r--r-- | sys/netinet/ip_output.c | 4 |
5 files changed, 11 insertions, 15 deletions
diff --git a/sys/net/bridge.c b/sys/net/bridge.c index f7bc63e..9878788 100644 --- a/sys/net/bridge.c +++ b/sys/net/bridge.c @@ -508,9 +508,7 @@ bdg_forward (struct mbuf **m0, struct ifnet *dst) * processing was already done, and we need to go down. */ rule = (struct ip_fw_chain *)(m->m_data) ; - (*m0) = m->m_next ; - FREE(m, M_IPFW); - m = *m0 ; + (*m0) = m = m->m_next ; src = m->m_pkthdr.rcvif; /* could be NULL in output */ eh = mtod(m, struct ether_header *); /* XXX */ diff --git a/sys/netinet/in.h b/sys/netinet/in.h index 0fe16f4..5d67085 100644 --- a/sys/netinet/in.h +++ b/sys/netinet/in.h @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)in.h 8.3 (Berkeley) 1/3/94 - * $Id: in.h,v 1.39 1999/04/20 13:32:04 peter Exp $ + * $Id: in.h,v 1.40 1999/04/28 11:37:43 phk Exp $ */ #ifndef _NETINET_IN_H_ @@ -140,7 +140,8 @@ #define IPPROTO_ENCAP 98 /* encapsulation header */ #define IPPROTO_APES 99 /* any private encr. scheme */ #define IPPROTO_GMTP 100 /* GMTP*/ -/* 101-254: Unassigned */ +/* 101-254: Partly Unassigned */ +#define IPPROTO_PGM 113 /* PGM */ /* 255: Reserved */ /* BSD Private, local use, namespace incursion */ #define IPPROTO_DIVERT 254 /* divert pseudo-protocol */ diff --git a/sys/netinet/ip_dummynet.c b/sys/netinet/ip_dummynet.c index 024998c..49439fd 100644 --- a/sys/netinet/ip_dummynet.c +++ b/sys/netinet/ip_dummynet.c @@ -10,7 +10,7 @@ * * This software is provided ``AS IS'' without any warranties of any kind. * - * $Id: ip_dummynet.c,v 1.12 1999/04/20 13:32:04 peter Exp $ + * $Id: ip_dummynet.c,v 1.13 1999/05/04 07:30:07 luigi Exp $ */ /* @@ -211,8 +211,9 @@ dn_move(struct dn_pipe *pipe, int immediate) * m_next = the actual mbuf to be processed by ip_input/output * m_data = the matching rule * The vestigial element is the same memory area used by - * the dn_pkt, and IS FREED IN ip_input/ip_output. IT IS - * NOT A REAL MBUF, just a block of memory acquired with malloc(). + * the dn_pkt, and IS FREED HERE because it can contain + * parameters passed to the called routine. The buffer IS NOT + * A REAL MBUF, just a block of memory acquired with malloc(). */ switch (pkt->dn_dir) { case DN_TO_IP_OUT: { @@ -239,9 +240,9 @@ dn_move(struct dn_pipe *pipe, int immediate) default: printf("dummynet: bad switch %d!\n", pkt->dn_dir); m_freem(pkt->dn_m); - FREE(pkt, M_IPFW); break ; } + FREE(pkt, M_IPFW); } } /* diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c index 1d72f8a..e8cb192 100644 --- a/sys/netinet/ip_input.c +++ b/sys/netinet/ip_input.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)ip_input.c 8.2 (Berkeley) 1/4/94 - * $Id: ip_input.c,v 1.117 1999/04/20 13:32:05 peter Exp $ + * $Id: ip_input.c,v 1.118 1999/05/03 23:57:29 billf Exp $ */ #define _IP_VHL @@ -256,10 +256,8 @@ ip_input(struct mbuf *m) * rule. */ if (m->m_type == MT_DUMMYNET) { - struct mbuf *m0 = m ; rule = (struct ip_fw_chain *)(m->m_data) ; m = m->m_next ; - free(m0, M_IPFW); ip = mtod(m, struct ip *); hlen = IP_VHL_HL(ip->ip_vhl) << 2; goto iphack ; diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 2e5d824..e0d8de3 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)ip_output.c 8.3 (Berkeley) 1/21/94 - * $Id: ip_output.c,v 1.88 1999/04/20 13:32:06 peter Exp $ + * $Id: ip_output.c,v 1.89 1999/05/04 09:26:12 luigi Exp $ */ #define _IP_VHL @@ -139,7 +139,6 @@ ip_output(m0, opt, ro, flags, imo) * rule. */ if (m->m_type == MT_DUMMYNET) { - struct mbuf *tmp_m = m ; /* * the packet was already tagged, so part of the * processing was already done, and we need to go down. @@ -148,7 +147,6 @@ ip_output(m0, opt, ro, flags, imo) */ rule = (struct ip_fw_chain *)(m->m_data) ; m0 = m = m->m_next ; - free(tmp_m, M_IPFW); ip = mtod(m, struct ip *); dst = (struct sockaddr_in *)flags ; ifp = (struct ifnet *)opt; |