Merge pull request #10982 from julek-wolfssl/dtls-clear-tx-cursor-on-free

DTLS: clear dtls_tx_msg cursor when its record is freed
This commit is contained in:
Sean Parkinson
2026-07-24 13:24:52 +10:00
committed by GitHub
+4 -1
View File
@@ -9926,8 +9926,11 @@ void DtlsTxMsgListClean(WOLFSSL* ssl)
WOLFSSL_ENTER("DtlsTxMsgListClean"); WOLFSSL_ENTER("DtlsTxMsgListClean");
while (head) { while (head) {
next = head->next; next = head->next;
if (VerifyForTxDtlsMsgDelete(ssl, head)) if (VerifyForTxDtlsMsgDelete(ssl, head)) {
if (ssl->dtls_tx_msg == head)
ssl->dtls_tx_msg = NULL;
DtlsMsgDelete(head, ssl->heap); DtlsMsgDelete(head, ssl->heap);
}
else else
/* Stored packets should be in order so break on first failed /* Stored packets should be in order so break on first failed
* verify */ * verify */