uipc_mbuf.c (55171) | uipc_mbuf.c (62587) |
---|---|
1/* 2 * Copyright (c) 1982, 1986, 1988, 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 17 unchanged lines hidden (view full) --- 26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * 33 * @(#)uipc_mbuf.c 8.2 (Berkeley) 1/4/94 | 1/* 2 * Copyright (c) 1982, 1986, 1988, 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 17 unchanged lines hidden (view full) --- 26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * 33 * @(#)uipc_mbuf.c 8.2 (Berkeley) 1/4/94 |
34 * $FreeBSD: head/sys/kern/uipc_mbuf.c 55171 1999-12-28 06:35:57Z msmith $ | 34 * $FreeBSD: head/sys/kern/uipc_mbuf.c 62587 2000-07-04 16:35:15Z itojun $ |
35 */ 36 37#include "opt_param.h" 38#include <sys/param.h> 39#include <sys/systm.h> 40#include <sys/malloc.h> 41#include <sys/mbuf.h> 42#include <sys/kernel.h> --- 471 unchanged lines hidden (view full) --- 514m_freem(m) 515 register struct mbuf *m; 516{ 517 register struct mbuf *n; 518 519 if (m == NULL) 520 return; 521 do { | 35 */ 36 37#include "opt_param.h" 38#include <sys/param.h> 39#include <sys/systm.h> 40#include <sys/malloc.h> 41#include <sys/mbuf.h> 42#include <sys/kernel.h> --- 471 unchanged lines hidden (view full) --- 514m_freem(m) 515 register struct mbuf *m; 516{ 517 register struct mbuf *n; 518 519 if (m == NULL) 520 return; 521 do { |
522 /* 523 * we do need to check non-first mbuf, since some of existing 524 * code does not call M_PREPEND properly. 525 * (example: call to bpf_mtap from drivers) 526 */ 527 if ((m->m_flags & M_PKTHDR) != 0 && m->m_pkthdr.aux) { 528 m_freem(m->m_pkthdr.aux); 529 m->m_pkthdr.aux = NULL; 530 } |
|
522 MFREE(m, n); 523 m = n; 524 } while (m); 525} 526 527/* 528 * Mbuffer utility routines. 529 */ --- 656 unchanged lines hidden --- | 531 MFREE(m, n); 532 m = n; 533 } while (m); 534} 535 536/* 537 * Mbuffer utility routines. 538 */ --- 656 unchanged lines hidden --- |