projects
/
dragonfly.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
139517b
)
tcp timer: Don't try stopping timers if timer message is not created.
author
Sepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 23 May 2009 11:01:15 +0000 (19:01 +0800)
committer
Sepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 23 May 2009 11:33:08 +0000 (19:33 +0800)
DragonFly-bug: <http://bugs.dragonflybsd.org/issue1380>
sys/netinet/tcp_subr.c
patch
|
blob
|
blame
|
history
diff --git
a/sys/netinet/tcp_subr.c
b/sys/netinet/tcp_subr.c
index
7c08586
..
817c258
100644
(file)
--- a/
sys/netinet/tcp_subr.c
+++ b/
sys/netinet/tcp_subr.c
@@
-859,9
+859,10
@@
tcp_close(struct tcpcb *tp)
/*
* Make sure that all of our timers are stopped before we
* delete the PCB. For listen TCP socket (tp->tt_msg == NULL),
- * timers are never used.
+ * timers are never used. If timer message is never created
+ * (tp->tt_msg->tt_tcb == NULL), timers are never used too.
*/
- if (tp->tt_msg != NULL) {
+ if (tp->tt_msg != NULL && tp->tt_msg->tt_tcb != NULL) {
tcp_callout_stop(tp, tp->tt_rexmt);
tcp_callout_stop(tp, tp->tt_persist);
tcp_callout_stop(tp, tp->tt_keep);