//
// sub_110A210 from 0x110a210 to 0x110a2a8 (152 bytes)
//
// 2 xrefs:
// > __emutls_get_address @ 0x110a2d4
// > __emutls_get_address @ 0x110a3dc
//
// 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 13:18:31 +0000
//
_QWORD *__fastcall sub_110A210(size_t *a1)
{
unsigned __int64 v1; // x20
size_t v3; // x0
_QWORD *v4; // x0
_QWORD *v5; // x19
void *v6; // x0
const void *v7; // x1
size_t v8; // x2
v1 = a1[1];
v3 = *a1;
if ( v1 > 8 )
{
v6 = malloc(v1 + v3 + 7);
if ( !v6 )
LABEL_3:
abort();
v5 = (_QWORD *)(((unsigned __int64)v6 + v1 + 7) & -(__int64)v1);
*(v5 - 1) = v6;
}
else
{
v4 = malloc(v3 + 8);
if ( !v4 )
goto LABEL_3;
*v4 = v4;
v5 = v4 + 1;
}
v7 = (const void *)a1[3];
v8 = *a1;
if ( v7 )
memcpy(v5, v7, v8);
else
memset(v5, 0, v8);
return v5;
}