//
// dtls1_read_failed from 0xd4d208 to 0xd4d294 (140 bytes)
//
// 2 xrefs:
// > dtls1_read_bytes @ 0xd311fc
// > ??> @ 0x32280
//
// 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_read_failed(__int64 a1, int a2)
{
unsigned int v3; // w19
__int64 rbio; // x0
if ( a2 > 0 )
{
v3 = 1;
ERR_put_error(20, 339, 68, "ssl/statem/statem_dtls.c", 928);
return v3;
}
v3 = a2;
if ( !(unsigned int)dtls1_is_timer_expired() )
return v3;
if ( !(unsigned int)SSL_in_init(a1) )
{
rbio = SSL_get_rbio(a1);
BIO_set_flags(rbio, 1);
return v3;
}
return dtls1_handle_timeout(a1);
}