1
This commit is contained in:
1 parent
57f3a9e37b
commit
8e8313769b
1 file changed
+4
-2
+4
-2
@@ -641,8 +641,9 @@ struct ETCP_DGRAM* etcp_request_pkt(struct ETCP_CONN* etcp) {
|
||||
inf_pkt->send_count++;
|
||||
inf_pkt->state=INFLIGHT_STATE_WAIT_ACK;
|
||||
queue_data_put(etcp->input_wait_ack, (struct ll_entry*)inf_pkt, inf_pkt->seq);// move dgram to wait_ack queue
|
||||
}
|
||||
|
||||
} else {
|
||||
queue_resume_callback(etcp->input_send_q);
|
||||
}
|
||||
size_t ack_q_size = queue_entry_count(etcp->ack_q);
|
||||
|
||||
if (!inf_pkt && ack_q_size == 0) {
|
||||
@@ -655,6 +656,7 @@ struct ETCP_DGRAM* etcp_request_pkt(struct ETCP_CONN* etcp) {
|
||||
if (!dgram) {
|
||||
DEBUG_ERROR(DEBUG_CATEGORY_ETCP, "[%s] failed to allocate ETCP_DGRAM", etcp->log_name);
|
||||
etcp->tx_state=ETCP_TX_STATE_ERR_MEM;
|
||||
// TODO: КОРРЕКТНО ОСВОБОДИТЬ ПАМЯТЬ
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user