tcp_output.c (146463) | tcp_output.c (151967) |
---|---|
1/*- 2 * Copyright (c) 1982, 1986, 1988, 1990, 1993, 1995 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 --- 13 unchanged lines hidden (view full) --- 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * @(#)tcp_output.c 8.4 (Berkeley) 5/24/95 | 1/*- 2 * Copyright (c) 1982, 1986, 1988, 1990, 1993, 1995 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 --- 13 unchanged lines hidden (view full) --- 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * @(#)tcp_output.c 8.4 (Berkeley) 5/24/95 |
30 * $FreeBSD: head/sys/netinet/tcp_output.c 146463 2005-05-21 00:38:29Z ps $ | 30 * $FreeBSD: head/sys/netinet/tcp_output.c 151967 2005-11-02 13:46:32Z andre $ |
31 */ 32 33#include "opt_inet.h" 34#include "opt_inet6.h" 35#include "opt_ipsec.h" 36#include "opt_mac.h" 37#include "opt_tcpdebug.h" 38#include "opt_tcp_sack.h" --- 703 unchanged lines hidden (view full) --- 742 goto out; 743 } 744 /* 745 * m_copypack left space for our hdr; use it. 746 */ 747 m->m_len += hdrlen; 748 m->m_data -= hdrlen; 749#else | 31 */ 32 33#include "opt_inet.h" 34#include "opt_inet6.h" 35#include "opt_ipsec.h" 36#include "opt_mac.h" 37#include "opt_tcpdebug.h" 38#include "opt_tcp_sack.h" --- 703 unchanged lines hidden (view full) --- 742 goto out; 743 } 744 /* 745 * m_copypack left space for our hdr; use it. 746 */ 747 m->m_len += hdrlen; 748 m->m_data -= hdrlen; 749#else |
750 MGETHDR(m, M_DONTWAIT, MT_HEADER); | 750 MGETHDR(m, M_DONTWAIT, MT_DATA); |
751 if (m == NULL) { 752 SOCKBUF_UNLOCK(&so->so_snd); 753 error = ENOBUFS; 754 goto out; 755 } 756#ifdef INET6 757 if (MHLEN < hdrlen + max_linkhdr) { 758 MCLGET(m, M_DONTWAIT); --- 36 unchanged lines hidden (view full) --- 795 tcpstat.tcps_sndacks++; 796 else if (flags & (TH_SYN|TH_FIN|TH_RST)) 797 tcpstat.tcps_sndctrl++; 798 else if (SEQ_GT(tp->snd_up, tp->snd_una)) 799 tcpstat.tcps_sndurg++; 800 else 801 tcpstat.tcps_sndwinup++; 802 | 751 if (m == NULL) { 752 SOCKBUF_UNLOCK(&so->so_snd); 753 error = ENOBUFS; 754 goto out; 755 } 756#ifdef INET6 757 if (MHLEN < hdrlen + max_linkhdr) { 758 MCLGET(m, M_DONTWAIT); --- 36 unchanged lines hidden (view full) --- 795 tcpstat.tcps_sndacks++; 796 else if (flags & (TH_SYN|TH_FIN|TH_RST)) 797 tcpstat.tcps_sndctrl++; 798 else if (SEQ_GT(tp->snd_up, tp->snd_una)) 799 tcpstat.tcps_sndurg++; 800 else 801 tcpstat.tcps_sndwinup++; 802 |
803 MGETHDR(m, M_DONTWAIT, MT_HEADER); | 803 MGETHDR(m, M_DONTWAIT, MT_DATA); |
804 if (m == NULL) { 805 error = ENOBUFS; 806 goto out; 807 } 808#ifdef INET6 809 if (isipv6 && (MHLEN < hdrlen + max_linkhdr) && 810 MHLEN >= hdrlen) { 811 MH_ALIGN(m, hdrlen); --- 370 unchanged lines hidden --- | 804 if (m == NULL) { 805 error = ENOBUFS; 806 goto out; 807 } 808#ifdef INET6 809 if (isipv6 && (MHLEN < hdrlen + max_linkhdr) && 810 MHLEN >= hdrlen) { 811 MH_ALIGN(m, hdrlen); --- 370 unchanged lines hidden --- |