//
// sub_5F938 from 0x5f938 to 0x5f970 (56 bytes)
//
// 3 xrefs:
// > sub_5F848 @ 0x5f8e8
// > sub_62E54 @ 0x62e6c
// > sub_62EE4 @ 0x62efc
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:13:53 +0000
//
_QWORD *__fastcall sub_5F938(_QWORD **a1, int a2)
{
_QWORD *result; // x0
int v4; // w9
if ( a2 < 0 )
return nullptr;
result = *a1;
if ( result == a1 )
return nullptr;
v4 = a2 + 1;
while ( --v4 >= 1 )
{
result = (_QWORD *)*result;
if ( result == a1 )
return nullptr;
}
return result;
}