//
// sub_CEE1CC from 0xcee1cc to 0xcee250 (132 bytes)
//
// 12 xrefs:
// > sub_CEE250 @ 0xcee360
// > sub_CEE3F8 @ 0xcee550
// > sub_CEE5B8 @ 0xcee730
// > sub_CEE964 @ 0xceed50
// > sub_CEEF5C @ 0xcef124
// > sub_CEF214 @ 0xcef3dc
// > sub_CEF458 @ 0xcef620
// > sub_CEF68C @ 0xcef854
// > sub_CEF8C0 @ 0xcefa88
// > sub_CEFAF4 @ 0xcefcc8
// > sub_CEFD3C @ 0xceff18
// > sub_CEFF84 @ 0xcf014c
//
// 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 sub_CEE1CC(__int64 result)
{
__int64 v1; // x19
__int64 v2; // x20
v1 = *(_QWORD *)(result + 8) + *(_QWORD *)(**(_QWORD **)(result + 8) - 24LL);
if ( (*(_DWORD *)(v1 + 24) & 0x2000) != 0 )
{
v2 = result;
result = std::uncaught_exception();
if ( !(_BYTE)result )
{
result = *(_QWORD *)(v1 + 232);
if ( result )
{
result = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)result + 48LL))(result);
if ( (_DWORD)result == -1 )
return sub_CCE830(
*(_QWORD *)(v2 + 8) + *(_QWORD *)(**(_QWORD **)(v2 + 8) - 24LL),
*(_DWORD *)(*(_QWORD *)(v2 + 8) + *(_QWORD *)(**(_QWORD **)(v2 + 8) - 24LL) + 32LL) | 1u);
}
}
}
return result;
}