//
// sub_1005B8798 from 0x1005b8798 to 0x1005b8804 (108 bytes)
//
// 2 xrefs:
// > sub_1005C4D00 @ 0x1005c5004
// > sub_1005C5694 @ 0x1005c59c4
//
// 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_1005B8798(__int64 a1, _QWORD *a2)
{
__int64 (*v2)(void); // x3
__int64 v3; // x2
__int64 v4; // x4
v2 = *(__int64 (**)(void))(*(_QWORD *)a1 + 200LL);
if ( !v2 )
{
v3 = 66;
v4 = 984;
goto LABEL_5;
}
if ( *(_QWORD *)a1 != *a2 )
{
v3 = 101;
v4 = 988;
LABEL_5:
sub_1005E0E48(16, 119, v3, "ec_lib.c", v4);
return 0;
}
return v2();
}