diff options
author | Michael Tuexen <tuexen@FreeBSD.org> | 2015-12-06 16:17:57 +0000 |
---|---|---|
committer | Michael Tuexen <tuexen@FreeBSD.org> | 2015-12-06 16:17:57 +0000 |
commit | c979034b18da66c6f65818748754d5fbe2901707 (patch) | |
tree | a643c8a1cec57c56f0ee5a56f08a51cba38a5191 /sys/netinet/sctputil.c | |
parent | d253cfe3b20c8540826d57e24fcc6afcbdc0429d (diff) | |
download | src-c979034b18da66c6f65818748754d5fbe2901707.tar.gz src-c979034b18da66c6f65818748754d5fbe2901707.zip |
Fix the allocation of outgoing streams:
* When processing a cookie, use the number of
streams announced in the INIT-ACK.
* When sending an INIT-ACK for an existing
association, use the value from the association,
not from the end-point.
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=291904
Diffstat (limited to 'sys/netinet/sctputil.c')
-rw-r--r-- | sys/netinet/sctputil.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/sctputil.c b/sys/netinet/sctputil.c index 8d8f375efcff..f2e9457806b4 100644 --- a/sys/netinet/sctputil.c +++ b/sys/netinet/sctputil.c @@ -938,7 +938,7 @@ sctp_map_assoc_state(int kernel_state) int sctp_init_asoc(struct sctp_inpcb *inp, struct sctp_tcb *stcb, - uint32_t override_tag, uint32_t vrf_id) + uint32_t override_tag, uint32_t vrf_id, uint16_t o_strms) { struct sctp_association *asoc; @@ -1100,7 +1100,7 @@ sctp_init_asoc(struct sctp_inpcb *inp, struct sctp_tcb *stcb, * that we request by default. */ asoc->strm_realoutsize = asoc->streamoutcnt = asoc->pre_open_streams = - inp->sctp_ep.pre_open_stream_count; + o_strms; SCTP_MALLOC(asoc->strmout, struct sctp_stream_out *, asoc->streamoutcnt * sizeof(struct sctp_stream_out), SCTP_M_STRMO); |