free memory to reduce the memory leaks

This commit is contained in:
laurent
2023-03-13 11:59:31 +01:00
parent 36783a3a79
commit a853a0873e
14 changed files with 54 additions and 39 deletions
+2 -1
View File
@@ -650,7 +650,8 @@ static void sctp_send_data(sctp_data_req_t *sctp_data_req_p)
/* TODO: notify upper layer */
return;
}
if ( sctp_data_req_p->freeAfterSend)
free(sctp_data_req_p->buffer);
SCTP_DEBUG("Successfully sent %u bytes on stream %d for assoc_id %u\n",
sctp_data_req_p->buffer_length, sctp_data_req_p->stream,
sctp_cnx->assoc_id);