// // sub_10043A8E0 from 0x10043a8e0 to 0x10043a9f9 (281 bytes) // // 2 xrefs: // > sub_100439970 @ 0x100439f68 // > sub_100439970 @ 0x100439f87 // // 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 // unsigned __int64 __fastcall sub_10043A8E0(unsigned __int64 *a1, char *a2, __int64 a3, unsigned __int64 a4) { char *v6; // rdi unsigned __int64 result; // rax unsigned __int64 v8; // r15 size_t v9; // r12 char *v10; // r15 size_t v11; // r14 size_t v12; // rdx char *v13; // r12 size_t v14; // r14 v6 = (char *)*a1; result = a1[2]; if ( result - (unsigned __int64)v6 < a4 ) { if ( v6 ) { a1[1] = (unsigned __int64)v6; v8 = a4; operator delete(v6); a4 = v8; *(_OWORD *)a1 = 0; a1[2] = 0; result = 0; } if ( (a4 & 0x8000000000000000LL) != 0LL ) sub_1000D4670(); if ( 2 * result > a4 ) a4 = 2 * result; v9 = 0x7FFFFFFFFFFFFFFFLL; if ( result < 0x3FFFFFFFFFFFFFFFLL ) v9 = a4; result = (unsigned __int64)operator new(v9); v10 = (char *)result; *a1 = result; a1[1] = result; a1[2] = result + v9; v11 = a3 - (_QWORD)a2; if ( v11 ) result = (unsigned __int64)memcpy((void *)result, a2, v11); LABEL_16: a1[1] = (unsigned __int64)&v10[v11]; return result; } v10 = (char *)a1[1]; v12 = v10 - v6; if ( v10 - v6 < a4 ) { v13 = &a2[v12]; if ( v10 != v6 ) { result = (unsigned __int64)memmove(v6, a2, v12); v10 = (char *)a1[1]; } v11 = a3 - (_QWORD)v13; if ( v11 ) result = (unsigned __int64)memmove(v10, v13, v11); goto LABEL_16; } v14 = a3 - (_QWORD)a2; if ( v14 ) result = (unsigned __int64)memmove(v6, a2, v14); a1[1] = (unsigned __int64)&v6[v14]; return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source