; ; __acrt_mbs_to_wcs_cp<__crt_win32_buffer_internal_dynamic_resizing> from 0x180128f50 to 0x1801290c6 (374 bytes) ; ; 5 xrefs: ; > _stat64i32 @ 0x180129904 ; > _wsetlocale_set_cat @ 0x180139f19 ; > __acrt_SetEnvironmentVariableA @ 0x1801410a3 ; > __acrt_SetEnvironmentVariableA @ 0x180141116 ; > @ 0x180202a5c ; ; 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 ; mov rax, rsp ; +0x0, 0x180128f50 mov [rax+8], rbx ; +0x3, 0x180128f53 mov [rax+10h], rbp ; +0x7, 0x180128f57 mov [rax+18h], rsi ; +0xb, 0x180128f5b mov [rax+20h], rdi ; +0xf, 0x180128f5f push r14 ; +0x13, 0x180128f63 sub rsp, 30h ; +0x15, 0x180128f65 xor ebx, ebx ; +0x19, 0x180128f69 mov ebp, r8d ; +0x1b, 0x180128f6b mov rdi, rdx ; +0x1e, 0x180128f6e mov rsi, rcx ; +0x21, 0x180128f71 test rcx, rcx ; +0x24, 0x180128f74 jnz short loc_180128F9B ; +0x27, 0x180128f77 cmp [rdx+28h], bl ; +0x29, 0x180128f79 jz short loc_180128F8A ; +0x2c, 0x180128f7c mov rcx, [rdx+10h]; Block ; +0x2e, 0x180128f7e call _free_base ; +0x32, 0x180128f82 mov [rdi+28h], bl ; +0x37, 0x180128f87 mov [rdi+10h], rbx ; +0x3a, 0x180128f8a mov [rdi+18h], rbx ; +0x3e, 0x180128f8e mov [rdi+20h], rbx ; +0x42, 0x180128f92 jmp loc_1801290A9 ; +0x46, 0x180128f96 cmp [rcx], bl ; +0x4b, 0x180128f9b jnz short loc_180128FF4 ; +0x4d, 0x180128f9d cmp [rdx+18h], rbx ; +0x4f, 0x180128f9f jnz short loc_180128FEB ; +0x53, 0x180128fa3 cmp [rdx+28h], bl ; +0x55, 0x180128fa5 jz short loc_180128FB6 ; +0x58, 0x180128fa8 mov rcx, [rdx+10h]; Block ; +0x5a, 0x180128faa call _free_base ; +0x5e, 0x180128fae mov [rdi+28h], bl ; +0x63, 0x180128fb3 mov ecx, 2; Size ; +0x66, 0x180128fb6 call _malloc_base ; +0x6b, 0x180128fbb mov [rdi+10h], rax ; +0x70, 0x180128fc0 mov rcx, rbx ; +0x74, 0x180128fc4 neg rax ; +0x77, 0x180128fc7 sbb edx, edx ; +0x7a, 0x180128fca not edx ; +0x7c, 0x180128fcc and edx, 0Ch ; +0x7e, 0x180128fce setz cl ; +0x81, 0x180128fd1 test edx, edx ; +0x84, 0x180128fd4 setz al ; +0x86, 0x180128fd6 mov [rdi+28h], al ; +0x89, 0x180128fd9 mov [rdi+18h], rcx ; +0x8c, 0x180128fdc test edx, edx ; +0x90, 0x180128fe0 jz short loc_180128FEB ; +0x92, 0x180128fe2 mov ebx, edx ; +0x94, 0x180128fe4 jmp loc_1801290A9 ; +0x96, 0x180128fe6 mov rax, [rdi+10h] ; +0x9b, 0x180128feb mov [rax], bx ; +0x9f, 0x180128fef jmp short loc_180128F92 ; +0xa2, 0x180128ff2 or r9d, 0FFFFFFFFh ; +0xa4, 0x180128ff4 mov [rsp+38h+var_10], ebx ; +0xa8, 0x180128ff8 mov r8, rsi ; +0xac, 0x180128ffc mov [rsp+38h+var_18], rbx ; +0xaf, 0x180128fff mov ecx, ebp ; +0xb4, 0x180129004 lea edx, [r9+0Ah] ; +0xb6, 0x180129006 call __acrt_MultiByteToWideChar ; +0xba, 0x18012900a movsxd r14, eax ; +0xbf, 0x18012900f test eax, eax ; +0xc2, 0x180129012 jnz short loc_18012902C ; +0xc4, 0x180129014 call cs:GetLastError ; +0xc6, 0x180129016 mov ecx, eax ; +0xcc, 0x18012901c call __acrt_errno_map_os_error ; +0xce, 0x18012901e call _errno ; +0xd3, 0x180129023 mov ebx, [rax] ; +0xd8, 0x180129028 jmp short loc_1801290A9 ; +0xda, 0x18012902a mov rcx, [rdi+18h] ; +0xdc, 0x18012902c cmp r14, rcx ; +0xe0, 0x180129030 jbe short loc_180129078 ; +0xe3, 0x180129033 cmp [rdi+28h], bl ; +0xe5, 0x180129035 jz short loc_180129046 ; +0xe8, 0x180129038 mov rcx, [rdi+10h]; Block ; +0xea, 0x18012903a call _free_base ; +0xee, 0x18012903e mov [rdi+28h], bl ; +0xf3, 0x180129043 lea rcx, [r14+r14]; Size ; +0xf6, 0x180129046 call _malloc_base ; +0xfa, 0x18012904a mov [rdi+10h], rax ; +0xff, 0x18012904f mov rcx, rbx ; +0x103, 0x180129053 neg rax ; +0x106, 0x180129056 sbb edx, edx ; +0x109, 0x180129059 not edx ; +0x10b, 0x18012905b and edx, 0Ch ; +0x10d, 0x18012905d cmovz rcx, r14 ; +0x110, 0x180129060 test edx, edx ; +0x114, 0x180129064 setz al ; +0x116, 0x180129066 mov [rdi+28h], al ; +0x119, 0x180129069 mov [rdi+18h], rcx ; +0x11c, 0x18012906c test edx, edx ; +0x120, 0x180129070 jnz loc_180128FE4 ; +0x122, 0x180129072 mov rax, [rdi+10h] ; +0x128, 0x180129078 or r9d, 0FFFFFFFFh ; +0x12c, 0x18012907c mov [rsp+38h+var_10], ecx ; +0x130, 0x180129080 mov r8, rsi ; +0x134, 0x180129084 mov ecx, ebp ; +0x137, 0x180129087 mov [rsp+38h+var_18], rax ; +0x139, 0x180129089 lea edx, [r9+0Ah] ; +0x13e, 0x18012908e call __acrt_MultiByteToWideChar ; +0x142, 0x180129092 movsxd rcx, eax ; +0x147, 0x180129097 test eax, eax ; +0x14a, 0x18012909a jz loc_180129016 ; +0x14c, 0x18012909c dec rcx ; +0x152, 0x1801290a2 mov [rdi+20h], rcx ; +0x155, 0x1801290a5 mov rbp, [rsp+38h+arg_8] ; +0x159, 0x1801290a9 mov eax, ebx ; +0x15e, 0x1801290ae mov rbx, [rsp+38h+arg_0] ; +0x160, 0x1801290b0 mov rsi, [rsp+38h+arg_10] ; +0x165, 0x1801290b5 mov rdi, [rsp+38h+arg_18] ; +0x16a, 0x1801290ba add rsp, 30h ; +0x16f, 0x1801290bf pop r14 ; +0x173, 0x1801290c3 retn ; +0x175, 0x1801290c5