sctp_indata.c (170091) | sctp_indata.c (170138) |
---|---|
1/*- 2 * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are met: 6 * 7 * a) Redistributions of source code must retain the above copyright notice, 8 * this list of conditions and the following disclaimer. --- 17 unchanged lines hidden (view full) --- 26 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 28 * THE POSSIBILITY OF SUCH DAMAGE. 29 */ 30 31/* $KAME: sctp_indata.c,v 1.36 2005/03/06 16:04:17 itojun Exp $ */ 32 33#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are met: 6 * 7 * a) Redistributions of source code must retain the above copyright notice, 8 * this list of conditions and the following disclaimer. --- 17 unchanged lines hidden (view full) --- 26 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 28 * THE POSSIBILITY OF SUCH DAMAGE. 29 */ 30 31/* $KAME: sctp_indata.c,v 1.36 2005/03/06 16:04:17 itojun Exp $ */ 32 33#include <sys/cdefs.h> |
34__FBSDID("$FreeBSD: head/sys/netinet/sctp_indata.c 170091 2007-05-29 09:29:03Z rrs $"); | 34__FBSDID("$FreeBSD: head/sys/netinet/sctp_indata.c 170138 2007-05-30 17:39:45Z rrs $"); |
35 36#include <netinet/sctp_os.h> 37#include <netinet/sctp_var.h> 38#include <netinet/sctp_sysctl.h> 39#include <netinet/sctp_pcb.h> 40#include <netinet/sctp_header.h> 41#include <netinet/sctputil.h> 42#include <netinet/sctp_output.h> --- 1434 unchanged lines hidden (view full) --- 1477 gap = (MAX_TSN - asoc->mapping_array_base_tsn) + tsn + 1; 1478 } 1479 if (gap >= (SCTP_MAPPING_ARRAY << 3)) { 1480 /* Can't hold the bit in the mapping at max array, toss it */ 1481 return (0); 1482 } 1483 if (gap >= (uint32_t) (asoc->mapping_array_size << 3)) { 1484 SCTP_TCB_LOCK_ASSERT(stcb); | 35 36#include <netinet/sctp_os.h> 37#include <netinet/sctp_var.h> 38#include <netinet/sctp_sysctl.h> 39#include <netinet/sctp_pcb.h> 40#include <netinet/sctp_header.h> 41#include <netinet/sctputil.h> 42#include <netinet/sctp_output.h> --- 1434 unchanged lines hidden (view full) --- 1477 gap = (MAX_TSN - asoc->mapping_array_base_tsn) + tsn + 1; 1478 } 1479 if (gap >= (SCTP_MAPPING_ARRAY << 3)) { 1480 /* Can't hold the bit in the mapping at max array, toss it */ 1481 return (0); 1482 } 1483 if (gap >= (uint32_t) (asoc->mapping_array_size << 3)) { 1484 SCTP_TCB_LOCK_ASSERT(stcb); |
1485 if (sctp_expand_mapping_array(asoc)) { | 1485 if (sctp_expand_mapping_array(asoc, gap)) { |
1486 /* Can't expand, drop it */ 1487 return (0); 1488 } 1489 } 1490 if (compare_with_wrap(tsn, *high_tsn, MAX_TSN)) { 1491 *high_tsn = tsn; 1492 } 1493 /* See if we have received this one already */ --- 4443 unchanged lines hidden --- | 1486 /* Can't expand, drop it */ 1487 return (0); 1488 } 1489 } 1490 if (compare_with_wrap(tsn, *high_tsn, MAX_TSN)) { 1491 *high_tsn = tsn; 1492 } 1493 /* See if we have received this one already */ --- 4443 unchanged lines hidden --- |