MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sctp_reset_out_streams

Function sctp_reset_out_streams

freebsd/netinet/sctp_input.c:3358–3381  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3356}
3357
3358static void
3359sctp_reset_out_streams(struct sctp_tcb *stcb, uint32_t number_entries, uint16_t *list)
3360{
3361 uint32_t i;
3362 uint16_t temp;
3363
3364 if (number_entries > 0) {
3365 for (i = 0; i < number_entries; i++) {
3366 temp = ntohs(list[i]);
3367 if (temp >= stcb->asoc.streamoutcnt) {
3368 /* no such stream */
3369 continue;
3370 }
3371 stcb->asoc.strmout[temp].next_mid_ordered = 0;
3372 stcb->asoc.strmout[temp].next_mid_unordered = 0;
3373 }
3374 } else {
3375 for (i = 0; i < stcb->asoc.streamoutcnt; i++) {
3376 stcb->asoc.strmout[i].next_mid_ordered = 0;
3377 stcb->asoc.strmout[i].next_mid_unordered = 0;
3378 }
3379 }
3380 sctp_ulp_notify(SCTP_NOTIFY_STR_RESET_SEND, stcb, number_entries, (void *)list, SCTP_SO_NOT_LOCKED);
3381}
3382
3383static void
3384sctp_reset_clear_pending(struct sctp_tcb *stcb, uint32_t number_entries, uint16_t *list)

Calls 1

sctp_ulp_notifyFunction · 0.85

Tested by

no test coverage detected