diff options
author | tuexen <tuexen@FreeBSD.org> | 2010-09-15 23:10:45 +0000 |
---|---|---|
committer | tuexen <tuexen@FreeBSD.org> | 2010-09-15 23:10:45 +0000 |
commit | 790dcded4d97b3159e5d8054665dac9b6202a524 (patch) | |
tree | a6cd85d329bcee3455f52bea51bdb692ec388986 /sys/netinet/sctp_pcb.c | |
parent | 989dcde2a6d367ac9159492566c30f0d0f398152 (diff) | |
download | FreeBSD-src-790dcded4d97b3159e5d8054665dac9b6202a524.zip FreeBSD-src-790dcded4d97b3159e5d8054665dac9b6202a524.tar.gz |
Delay the assignment of a path for DATA chunk until they hit
the sent_queue. Honor a given path when the SCTP_ADDR_OVER
flag is set.
MFC after: 2 weeks.
Diffstat (limited to 'sys/netinet/sctp_pcb.c')
-rw-r--r-- | sys/netinet/sctp_pcb.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/sys/netinet/sctp_pcb.c b/sys/netinet/sctp_pcb.c index de18c2e..e7b5553 100644 --- a/sys/netinet/sctp_pcb.c +++ b/sys/netinet/sctp_pcb.c @@ -4843,7 +4843,10 @@ sctp_free_assoc(struct sctp_inpcb *inp, struct sctp_tcb *stcb, int from_inpcbfre sp->tail_mbuf = NULL; } } - sctp_free_remote_addr(sp->net); + if (sp->net) { + sctp_free_remote_addr(sp->net); + sp->net = NULL; + } sctp_free_spbufspace(stcb, asoc, sp); if (sp->holds_key_ref) sctp_auth_key_release(stcb, sp->auth_keyid); @@ -4914,7 +4917,10 @@ sctp_free_assoc(struct sctp_inpcb *inp, struct sctp_tcb *stcb, int from_inpcbfre if (chk->holds_key_ref) sctp_auth_key_release(stcb, chk->auth_keyid); ccnt++; - sctp_free_remote_addr(chk->whoTo); + if (chk->whoTo) { + sctp_free_remote_addr(chk->whoTo); + chk->whoTo = NULL; + } SCTP_ZONE_FREE(SCTP_BASE_INFO(ipi_zone_chunk), chk); SCTP_DECR_CHK_COUNT(); /* sa_ignore FREED_MEMORY */ |