Date: Sat, 19 May 2018 05:55:00 +0000 (UTC) From: Matt Macy <mmacy@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r333867 - head/sys/netinet Message-ID: <201805190555.w4J5t0IM078511@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mmacy Date: Sat May 19 05:55:00 2018 New Revision: 333867 URL: https://svnweb.freebsd.org/changeset/base/333867 Log: tcp fastopen: fix may be uninitialized Modified: head/sys/netinet/tcp_fastopen.c Modified: head/sys/netinet/tcp_fastopen.c ============================================================================== --- head/sys/netinet/tcp_fastopen.c Sat May 19 05:37:58 2018 (r333866) +++ head/sys/netinet/tcp_fastopen.c Sat May 19 05:55:00 2018 (r333867) @@ -856,6 +856,7 @@ tcp_fastopen_connect(struct tcpcb *tp) uint16_t server_mss; uint64_t psk_cookie; + psk_cookie = 0; inp = tp->t_inpcb; cce = tcp_fastopen_ccache_lookup(&inp->inp_inc, &ccb); if (cce) { @@ -875,7 +876,7 @@ tcp_fastopen_connect(struct tcpcb *tp) server_mss = cce->server_mss; CCB_UNLOCK(ccb); if (tp->t_tfo_client_cookie_len == - TCP_FASTOPEN_PSK_LEN) { + TCP_FASTOPEN_PSK_LEN && psk_cookie) { tp->t_tfo_client_cookie_len = TCP_FASTOPEN_COOKIE_LEN; memcpy(tp->t_tfo_cookie.client, &psk_cookie,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201805190555.w4J5t0IM078511>