call icmp6_mtudisc_update(foo, 0) even if ICMPv6 messages are very short.
let icmp6 layer decide whether we take PMTUD routes or not.
This commit is contained in:
parent
c9b9613b3e
commit
a7596d1912
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: tcp_subr.c,v 1.109 2001/03/21 03:35:11 chs Exp $ */
|
||||
/* $NetBSD: tcp_subr.c,v 1.110 2001/05/24 07:22:27 itojun Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
|
@ -1170,8 +1170,11 @@ tcp6_ctlinput(cmd, sa, d)
|
|||
*/
|
||||
|
||||
/* check if we can safely examine src and dst ports */
|
||||
if (m->m_pkthdr.len < off + sizeof(th))
|
||||
if (m->m_pkthdr.len < off + sizeof(th)) {
|
||||
if (cmd == PRC_MSGSIZE)
|
||||
icmp6_mtudisc_update((struct ip6ctlparam *)d, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
bzero(&th, sizeof(th));
|
||||
m_copydata(m, off, sizeof(th), (caddr_t)&th);
|
||||
|
@ -1251,6 +1254,8 @@ tcp_ctlinput(cmd, sa, v)
|
|||
* Check to see if we have a valid TCP connection
|
||||
* corresponding to the address in the ICMP message
|
||||
* payload.
|
||||
*
|
||||
* Boundary check is made in icmp_input(), with ICMP_ADVLENMIN.
|
||||
*/
|
||||
th = (struct tcphdr *)((caddr_t)ip + (ip->ip_hl << 2));
|
||||
if (in_pcblookup_connect(&tcbtable,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: udp6_usrreq.c,v 1.41 2001/05/08 10:15:15 itojun Exp $ */
|
||||
/* $NetBSD: udp6_usrreq.c,v 1.42 2001/05/24 07:22:28 itojun Exp $ */
|
||||
/* $KAME: udp6_usrreq.c,v 1.84 2001/02/07 07:38:25 itojun Exp $ */
|
||||
|
||||
/*
|
||||
|
@ -521,8 +521,11 @@ udp6_ctlinput(cmd, sa, d)
|
|||
*/
|
||||
|
||||
/* check if we can safely examine src and dst ports */
|
||||
if (m->m_pkthdr.len < off + sizeof(*uhp))
|
||||
if (m->m_pkthdr.len < off + sizeof(*uhp)) {
|
||||
if (cmd == PRC_MSGSIZE)
|
||||
icmp6_mtudisc_update((struct ip6ctlparam *)d, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
bzero(&uh, sizeof(uh));
|
||||
m_copydata(m, off, sizeof(*uhp), (caddr_t)&uh);
|
||||
|
|
Loading…
Reference in New Issue