//
// sub_D17FE0 from 0xd17fe0 to 0xd1804c (108 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
//
int **__usercall sub_D17FE0@(int **a1@, int **a2@)
{
int *v2; // x1
int v4; // w3
int **v6; // [xsp+28h] [xbp+28h]
v2 = *a1;
v4 = *(*a1 - 2);
if ( (v4 & 0x80000000) == 0 && *a1 - 6 != (int *)&qword_124B6B0 )
{
if ( v4 )
{
v6 = a2;
sub_D174B8(a1, 0, 0, 0);
v2 = *a1;
a2 = v6;
}
*(v2 - 2) = -1;
}
*a2 = v2;
return a2;
}