//
// sub_774C04 from 0x774c04 to 0x774c40 (60 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
//
unsigned int __fastcall sub_774C04(_DWORD *a1, void *a2, unsigned int a3, size_t a4)
{
unsigned int v4; // r4
unsigned int v5; // r6
unsigned __int8 *v8; // r5
int v9; // t1
v4 = a3;
v5 = *(_DWORD *)(*a1 - 12);
if ( a3 >= v5 )
return -1;
v8 = (unsigned __int8 *)(*a1 + a3);
while ( 1 )
{
v9 = *v8++;
if ( !memchr(a2, v9, a4) )
break;
if ( ++v4 >= v5 )
return -1;
}
return v4;
}