{"type": "func", "start": 6443717132, "end": 6443717235, "name": "replace_current_thread_locale_nolock", "pseudocode": "// \n// replace_current_thread_locale_nolock from 0x18013520c to 0x180135273 (103 bytes)\n// \n// 3 xrefs:\n// > __crt_seh_guarded_call<void>::operator @ 0x180134f61\n// > __crt_seh_guarded_call<void>::operator @ 0x180134fa9\n// > <???> @ 0x180203344\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\nvoid __fastcall replace_current_thread_locale_nolock(struct __acrt_ptd *const a1, struct __crt_locale_data *const a2)\n{\n  wchar_t **v4; // rcx\n\n  if ( *((_QWORD *)a1 + 18) )\n  {\n    _acrt_release_locale_ref();\n    v4 = *((wchar_t ***)a1 + 18);\n    if ( v4 != (wchar_t **)qword_1801F5158 && v4 != &off_1801B1880 && !*((_DWORD *)v4 + 4) )\n      _acrt_free_locale(v4);\n  }\n  *((_QWORD *)a1 + 18) = a2;\n  if ( a2 )\n    _acrt_add_locale_ref(a2);\n}", "assembly": "; \n; replace_current_thread_locale_nolock from 0x18013520c to 0x180135273 (103 bytes)\n; \n; 3 xrefs:\n; > __crt_seh_guarded_call<void>::operator @ 0x180134f61\n; > __crt_seh_guarded_call<void>::operator @ 0x180134fa9\n; > <???> @ 0x180203344\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, 0x18013520c\npush    rdi                                                            ; +0x5, 0x180135211\nsub     rsp, 20h                                                       ; +0x6, 0x180135212\nmov     rdi, rcx                                                       ; +0xa, 0x180135216\nmov     rbx, rdx                                                       ; +0xd, 0x180135219\nmov     rcx, [rcx+90h]                                                 ; +0x10, 0x18013521c\ntest    rcx, rcx                                                       ; +0x17, 0x180135223\njz      short loc_180135254                                            ; +0x1a, 0x180135226\ncall    __acrt_release_locale_ref                                      ; +0x1c, 0x180135228\nmov     rcx, [rdi+90h]; Block                                          ; +0x21, 0x18013522d\ncmp     rcx, cs:qword_1801F5158                                        ; +0x28, 0x180135234\njz      short loc_180135254                                            ; +0x2f, 0x18013523b\nlea     rax, off_1801B1880                                             ; +0x31, 0x18013523d\ncmp     rcx, rax                                                       ; +0x38, 0x180135244\njz      short loc_180135254                                            ; +0x3b, 0x180135247\ncmp     dword ptr [rcx+10h], 0                                         ; +0x3d, 0x180135249\njnz     short loc_180135254                                            ; +0x41, 0x18013524d\ncall    __acrt_free_locale                                             ; +0x43, 0x18013524f\nmov     [rdi+90h], rbx                                                 ; +0x48, 0x180135254\ntest    rbx, rbx                                                       ; +0x4f, 0x18013525b\njz      short loc_180135268                                            ; +0x52, 0x18013525e\nmov     rcx, rbx                                                       ; +0x54, 0x180135260\ncall    __acrt_add_locale_ref                                          ; +0x57, 0x180135263\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x5c, 0x180135268\nadd     rsp, 20h                                                       ; +0x61, 0x18013526d\npop     rdi                                                            ; +0x65, 0x180135271\nretn                                                                   ; +0x66, 0x180135272", "xrefs": ["__crt_seh_guarded_call<void>::operator @ 0x180134f61", "__crt_seh_guarded_call<void>::operator @ 0x180134fa9", "<???> @ 0x180203344"], "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"}