{"type": "func", "start": 6442728480, "end": 6442728591, "name": "sub_180043C20", "pseudocode": "// \n// sub_180043C20 from 0x180043c20 to 0x180043c8f (111 bytes)\n// \n// 2 xrefs:\n// > sub_180044E10 @ 0x180044f9a\n// > <???> @ 0x1801f8100\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\n__int64 __fastcall sub_180043C20(unsigned int a1, void **a2, _QWORD *a3)\n{\n  bool v4; // zf\n  __int64 v6; // r9\n  size_t v7; // rcx\n  __int64 result; // rax\n  void *v9; // rbx\n\n  v4 = a1 == 0;\n  v6 = 4LL * a1;\n  v7 = v6 + 1;\n  if ( !v4 )\n    v7 = v6;\n  result = (__int64)j__malloc_base(v7);\n  v9 = (void *)result;\n  if ( result )\n  {\n    if ( *a2 )\n      free(*a2);\n    *a2 = v9;\n    *a3 = v9;\n    return 1;\n  }\n  return result;\n}", "assembly": "; \n; sub_180043C20 from 0x180043c20 to 0x180043c8f (111 bytes)\n; \n; 2 xrefs:\n; > sub_180044E10 @ 0x180044f9a\n; > <???> @ 0x1801f8100\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x180043c20\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x180043c25\npush    rdi                                                            ; +0xa, 0x180043c2a\nsub     rsp, 20h                                                       ; +0xb, 0x180043c2b\nmov     eax, ecx                                                       ; +0xf, 0x180043c2f\nmov     rsi, r8                                                        ; +0x11, 0x180043c31\ntest    rax, rax                                                       ; +0x14, 0x180043c34\nmov     rdi, rdx                                                       ; +0x17, 0x180043c37\nlea     r9, ds:0[rax*4]                                                ; +0x1a, 0x180043c3a\nlea     rcx, [r9+1]                                                    ; +0x22, 0x180043c42\ncmovnz  rcx, r9; Size                                                  ; +0x26, 0x180043c46\ncall    j__malloc_base                                                 ; +0x2a, 0x180043c4a\nmov     rbx, rax                                                       ; +0x2f, 0x180043c4f\ntest    rax, rax                                                       ; +0x32, 0x180043c52\njnz     short loc_180043C67                                            ; +0x35, 0x180043c55\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x37, 0x180043c57\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x3c, 0x180043c5c\nadd     rsp, 20h                                                       ; +0x41, 0x180043c61\npop     rdi                                                            ; +0x45, 0x180043c65\nretn                                                                   ; +0x46, 0x180043c66\nmov     rcx, [rdi]; Block                                              ; +0x47, 0x180043c67\ntest    rcx, rcx                                                       ; +0x4a, 0x180043c6a\njz      short loc_180043C74                                            ; +0x4d, 0x180043c6d\ncall    free                                                           ; +0x4f, 0x180043c6f\nmov     [rdi], rbx                                                     ; +0x54, 0x180043c74\nmov     eax, 1                                                         ; +0x57, 0x180043c77\nmov     [rsi], rbx                                                     ; +0x5c, 0x180043c7c\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x5f, 0x180043c7f\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x64, 0x180043c84\nadd     rsp, 20h                                                       ; +0x69, 0x180043c89\npop     rdi                                                            ; +0x6d, 0x180043c8d\nretn                                                                   ; +0x6e, 0x180043c8e", "xrefs": ["sub_180044E10 @ 0x180044f9a", "<???> @ 0x1801f8100"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}