diff options
author | bp <bp@FreeBSD.org> | 2000-06-14 05:56:53 +0000 |
---|---|---|
committer | bp <bp@FreeBSD.org> | 2000-06-14 05:56:53 +0000 |
commit | 9941e0786710b93c7b52eb1adf70c4c2ad6571e1 (patch) | |
tree | 33a8aaeaf36808b2513143c0f3e694d36178edfa /sys/net | |
parent | a93970294c3a44c9f13c9f3944c956d2eb38c8f4 (diff) | |
download | FreeBSD-src-9941e0786710b93c7b52eb1adf70c4c2ad6571e1.zip FreeBSD-src-9941e0786710b93c7b52eb1adf70c4c2ad6571e1.tar.gz |
Do not perform any opeartion with mbuf after it placed into
interface queue.
Tested by: Bosko Milekic <bmilekic@dsuper.net>
Diffstat (limited to 'sys/net')
-rw-r--r-- | sys/net/if_ethersubr.c | 10 | ||||
-rw-r--r-- | sys/net/if_fddisubr.c | 4 | ||||
-rw-r--r-- | sys/net/if_iso88025subr.c | 4 |
3 files changed, 9 insertions, 9 deletions
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index 8507d90..22101e7 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -392,13 +392,13 @@ ether_output(ifp, m, dst, rt0) splx(s); senderr(ENOBUFS); } + if (m->m_flags & M_MCAST) + ifp->if_omcasts++; IF_ENQUEUE(&ifp->if_snd, m); if ((ifp->if_flags & IFF_OACTIVE) == 0) (*ifp->if_start)(ifp); splx(s); ifp->if_obytes += len + sizeof (struct ether_header); - if (m->m_flags & M_MCAST) - ifp->if_omcasts++; return (error); bad: @@ -1065,13 +1065,13 @@ ngether_rcvdata(hook_p hook, struct mbuf *m, meta_p meta, splx(s); senderr(ENOBUFS); } + ifp->if_obytes += m->m_pkthdr.len; + if (m->m_flags & M_MCAST) + ifp->if_omcasts++; IF_ENQUEUE(&ifp->if_snd, m); if ((ifp->if_flags & IFF_OACTIVE) == 0) (*ifp->if_start)(ifp); splx(s); - ifp->if_obytes += m->m_pkthdr.len; - if (m->m_flags & M_MCAST) - ifp->if_omcasts++; return (error); bad: diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c index 21c10fc..b3a8ead 100644 --- a/sys/net/if_fddisubr.c +++ b/sys/net/if_fddisubr.c @@ -357,12 +357,12 @@ fddi_output(ifp, m, dst, rt0) senderr(ENOBUFS); } ifp->if_obytes += m->m_pkthdr.len; + if (m->m_flags & M_MCAST) + ifp->if_omcasts++; IF_ENQUEUE(&ifp->if_snd, m); if ((ifp->if_flags & IFF_OACTIVE) == 0) (*ifp->if_start)(ifp); splx(s); - if (m->m_flags & M_MCAST) - ifp->if_omcasts++; return (error); bad: diff --git a/sys/net/if_iso88025subr.c b/sys/net/if_iso88025subr.c index 3dd47b8..cd2c2d9 100644 --- a/sys/net/if_iso88025subr.c +++ b/sys/net/if_iso88025subr.c @@ -306,13 +306,13 @@ iso88025_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst, struct splx(s); senderr(ENOBUFS); } + if (m->m_flags & M_MCAST) + ifp->if_omcasts++; IF_ENQUEUE(&ifp->if_snd, m); if ((ifp->if_flags & IFF_OACTIVE) == 0) (*ifp->if_start)(ifp); splx(s); ifp->if_obytes += len + ISO88025_HDR_LEN + 8; - if (m->m_flags & M_MCAST) - ifp->if_omcasts++; return (error); bad: |