diff --git a/sys/netinet/sctp_usrreq.c b/sys/netinet/sctp_usrreq.c index 6a474e38e897..eafa2c97423e 100644 --- a/sys/netinet/sctp_usrreq.c +++ b/sys/netinet/sctp_usrreq.c @@ -4651,11 +4651,20 @@ sctp_setopt(struct socket *so, int optname, void *optval, size_t optsize, error = sctp_send_str_reset_req(stcb, strrst->srs_number_streams, strrst->srs_stream_list, send_in, 0, 0, 0, 0, 0); - } else + } else { error = sctp_send_stream_reset_out_if_possible(stcb, SCTP_SO_LOCKED); - if (!error) + } + if (error == 0) { sctp_chunk_output(inp, stcb, SCTP_OUTPUT_FROM_STRRST_REQ, SCTP_SO_LOCKED); - + } else { + /* + * For outgoing streams don't report any + * problems in sending the request to the + * application. XXX: Double check resetting + * incoming streams. + */ + error = 0; + } SCTP_TCB_UNLOCK(stcb); break; }