Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/netinet If called from syn_cache_add, we need to initial...



details:   https://anonhg.NetBSD.org/src/rev/29dd0ce19902
branches:  trunk
changeset: 583565:29dd0ce19902
user:      christos <christos%NetBSD.org@localhost>
date:      Fri Aug 12 14:41:00 2005 +0000

description:
If called from syn_cache_add, we need to initialize t_state before calling
tcp_dooptions. Pointed out by yamt.

diffstat:

 sys/netinet/tcp_input.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 292cc04df468 -r 29dd0ce19902 sys/netinet/tcp_input.c
--- a/sys/netinet/tcp_input.c   Fri Aug 12 14:08:16 2005 +0000
+++ b/sys/netinet/tcp_input.c   Fri Aug 12 14:41:00 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: tcp_input.c,v 1.235 2005/08/12 04:19:22 hubertf Exp $  */
+/*     $NetBSD: tcp_input.c,v 1.236 2005/08/12 14:41:00 christos Exp $ */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -150,7 +150,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.235 2005/08/12 04:19:22 hubertf Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.236 2005/08/12 14:41:00 christos Exp $");
 
 #include "opt_inet.h"
 #include "opt_ipsec.h"
@@ -4000,6 +4000,7 @@
 #ifdef TCP_SIGNATURE
                tb.t_flags |= (tp->t_flags & TF_SIGNATURE);
 #endif
+               tb.t_state = TCPS_LISTEN;
                if (tcp_dooptions(&tb, optp, optlen, th, m, m->m_pkthdr.len -
                    sizeof(struct tcphdr) - optlen - hlen, oi) < 0)
                        return (0);



Home | Main Index | Thread Index | Old Index