//
// sub_10065D9BC from 0x10065d9bc to 0x10065da20 (100 bytes)
//
// 2 xrefs:
// > sub_1006575E0 @ 0x100658174
// > sub_100658930 @ 0x100659254
//
// 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 11:10:56 +0000
//
__int64 *__fastcall sub_10065D9BC(__int64 *result)
{
unsigned __int64 v1; // x8
__int64 v2; // x11
unsigned __int64 v3; // x9
__int64 v4; // x10
_WORD *v5; // x11
unsigned __int64 v6; // x12
_WORD *v7; // x10
v1 = result[1];
if ( v1 )
{
v2 = *result;
v3 = v1 & 0xFFFFFFFFFFFFFFFELL;
if ( (v1 & 0xFFFFFFFFFFFFFFFELL) != 0 )
{
v4 = v2 + 48 * v3;
v5 = (_WORD *)(v2 + 50);
v6 = v1 & 0xFFFFFFFFFFFFFFFELL;
do
{
*(v5 - 24) = 0;
*v5 = 0;
v5 += 48;
v6 -= 2LL;
}
while ( v6 );
}
else
{
v3 = 0;
v4 = *result;
}
if ( v1 != v3 )
{
v7 = (_WORD *)(v4 + 2);
do
{
*v7 = 0;
v7 += 24;
++v3;
}
while ( v3 < v1 );
}
}
return result;
}