mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
For IPv6 access pointer to tcpcb only after we have checked it is valid.
Found by: Coverity's automated analysis (via Ted Unangst)
This commit is contained in:
parent
0b54748fec
commit
6f2d4ea6f8
2 changed files with 8 additions and 2 deletions
|
|
@ -1420,11 +1420,14 @@ tcp_mtudisc(inp, errno)
|
|||
u_int romtu;
|
||||
int mss;
|
||||
#ifdef INET6
|
||||
int isipv6 = (tp->t_inpcb->inp_vflag & INP_IPV6) != 0;
|
||||
int isipv6;
|
||||
#endif /* INET6 */
|
||||
bzero(&tao, sizeof(tao));
|
||||
|
||||
if (tp != NULL) {
|
||||
#ifdef INET6
|
||||
isipv6 = (tp->t_inpcb->inp_vflag & INP_IPV6) != 0;
|
||||
#endif
|
||||
maxmtu = tcp_hc_getmtu(&inp->inp_inc); /* IPv4 and IPv6 */
|
||||
romtu =
|
||||
#ifdef INET6
|
||||
|
|
|
|||
|
|
@ -1420,11 +1420,14 @@ tcp_mtudisc(inp, errno)
|
|||
u_int romtu;
|
||||
int mss;
|
||||
#ifdef INET6
|
||||
int isipv6 = (tp->t_inpcb->inp_vflag & INP_IPV6) != 0;
|
||||
int isipv6;
|
||||
#endif /* INET6 */
|
||||
bzero(&tao, sizeof(tao));
|
||||
|
||||
if (tp != NULL) {
|
||||
#ifdef INET6
|
||||
isipv6 = (tp->t_inpcb->inp_vflag & INP_IPV6) != 0;
|
||||
#endif
|
||||
maxmtu = tcp_hc_getmtu(&inp->inp_inc); /* IPv4 and IPv6 */
|
||||
romtu =
|
||||
#ifdef INET6
|
||||
|
|
|
|||
Loading…
Reference in a new issue