//
// OPENSSL_DIR_end from 0xdc0240 to 0xdc02b4 (116 bytes)
//
// 2 xrefs:
// > SSL_add_dir_cert_subjects_to_stack @ 0xd3b2b8
// > ??> @ 0x7d970
//
// 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 OPENSSL_DIR_end(void **a1)
{
DIR **v2; // x0
int v3; // w20
unsigned int v4; // w1
_DWORD *v5; // x0
if ( !a1 )
goto LABEL_5;
v2 = (DIR **)*a1;
if ( !v2 )
goto LABEL_5;
v3 = closedir(*v2);
free(*a1);
if ( v3 != -1 )
{
v4 = 1;
if ( !v3 )
return v4;
LABEL_5:
v5 = (_DWORD *)__errno();
v4 = 0;
*v5 = 22;
return v4;
}
return 0;
}