//
// sub_10005DA60 from 0x10005da60 to 0x10005dadf (127 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: pc, 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:19:40 +0000
//
void *__fastcall sub_10005DA60(__int64 a1, const char *a2)
{
void *v3; // rdi
size_t v4; // r15
char *v5; // r13
void *result; // rax
if ( (*(_BYTE *)(a1 + 9) & 2) != 0 )
{
v3 = *(void **)(a1 + 16);
if ( v3 )
operator delete[](v3);
}
*(_DWORD *)(a1 + 8) = 0;
*(_OWORD *)(a1 + 16) = 0;
v4 = strlen(a2);
v5 = (char *)operator new[](v4 + 1);
*(_QWORD *)(a1 + 16) = v5;
result = memcpy(v5, a2, v4 + 1);
*(_QWORD *)(a1 + 24) = &v5[v4];
*(_DWORD *)(a1 + 8) = 512;
return result;
}