//
// dtls1_clear_received_buffer from 0xd5ce80 to 0xd5cec4 (68 bytes)
//
// 5 xrefs:
// > dtls1_reset_seq_numbers @ 0xd31afc
// > tls_finish_handshake @ 0xd4e880
// > dtls1_free @ 0xd5cf2c
// > dtls1_clear @ 0xd5cfb0
// > ??> @ 0x91650
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall dtls1_clear_received_buffer(__int64 a1)
{
__int64 result; // x0
__int64 v3; // x19
while ( 1 )
{
result = pqueue_pop(*(_QWORD *)(*(_QWORD *)(a1 + 152) + 272LL));
v3 = result;
if ( !result )
break;
dtls1_hm_fragment_free(*(_QWORD *)(result + 8));
pitem_free(v3);
}
return result;
}