//
// sub_62AD90 from 0x62ad90 to 0x62ae10 (128 bytes)
//
// 0 xrefs:
//
// 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
//
int __fastcall sub_62AD90(
int a1,
void *(*a2)(size_t byte_count),
void (*a3)(void *p),
void *(*a4)(void *p, size_t byte_count),
char *(*a5)(const char *),
void *(*a6)(size_t item_count, size_t item_size))
{
bool v6; // zf
bool v8; // zf
int v9; // r4
v6 = a3 == nullptr;
if ( a3 )
v6 = a2 == nullptr;
if ( v6 )
return 2;
v8 = a5 == nullptr;
if ( a5 )
v8 = a4 == nullptr;
v9 = v8;
if ( !a6 )
v9 |= 1u;
if ( v9 )
return 2;
if ( dword_ACAEB8 )
{
++dword_ACAEB8;
return 0;
}
dword_ACAEB8 = 1;
off_ABAEAC = a2;
off_ABAEB0 = a3;
off_ABAEB4 = a4;
off_ABAEB8 = a5;
off_ABAEBC = a6;
if ( (a1 & 1) != 0 && !sub_645424() )
return 2;
sub_632624();
if ( (a1 & 4) != 0 )
dword_ACAEC0 = 1;
dword_ACAEBC = a1;
sub_623B60();
return 0;
}