{"type": "func", "start": 5369350192, "end": 5369350595, "name": "AutoSaveSettingsLayer::onOpenBackupDir", "pseudocode": "// \n// AutoSaveSettingsLayer::onOpenBackupDir from 0x14009c830 to 0x14009c9c3 (403 bytes)\n// \n// 2 xrefs:\n// > AutoSaveSettingsLayer::init @ 0x14009bc0a\n// > <???> @ 0x140912f20\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:26:05 +0000\n// \n\n// Hidden C++ exception states: #wind=2\nvoid __fastcall AutoSaveSettingsLayer::onOpenBackupDir(__int64 *a1)\n{\n  const CHAR *v2; // rcx\n  DWORD FileAttributesA; // eax\n  __int64 v4; // rbx\n  __int64 v5; // rdx\n  __int64 v6; // r8\n  __int64 v7; // rax\n  const CHAR *v8; // rcx\n  DWORD v9; // eax\n  const CHAR *v10; // r8\n  __int128 v11; // [rsp+30h] [rbp-29h] BYREF\n  __int64 v12; // [rsp+40h] [rbp-19h]\n  __int64 v13; // [rsp+48h] [rbp-11h]\n  __int128 *v14; // [rsp+50h] [rbp-9h]\n  LPCSTR lpFile[2]; // [rsp+60h] [rbp+7h] BYREF\n  __int64 v16; // [rsp+70h] [rbp+17h]\n  unsigned __int64 v17; // [rsp+78h] [rbp+1Fh]\n  LPCSTR lpFileName[4]; // [rsp+80h] [rbp+27h] BYREF\n\n  AutoSaveSettingsLayer::getCustomBackupDirectory(lpFileName);\n  if ( !lpFileName[2] )\n    goto LABEL_7;\n  v2 = (const CHAR *)lpFileName;\n  if ( lpFileName[3] > (LPCSTR)0xF )\n    v2 = lpFileName[0];\n  FileAttributesA = GetFileAttributesA(v2);\n  if ( FileAttributesA == -1 || (FileAttributesA & 0x10) == 0 )\n  {\n    v14 = &v11;\n    v11 = 0;\n    v12 = 0;\n    v13 = 15;\n    LOBYTE(v11) = 0;\n    *(_OWORD *)lpFile = 0;\n    v16 = 0;\n    v17 = 0;\n    lpFile[0] = (LPCSTR)sub_14003D460(0x20u);\n    v16 = 19;\n    v17 = 31;\n    strcpy((char *)lpFile[0], \"Directory not found\");\n    v4 = *a1;\n    v7 = TextAlertPopup::create(lpFile, v5, v6, 150, &v11);\n    (*(void (__fastcall **)(__int64 *, __int64, __int64))(v4 + 456))(a1, v7, 100);\n  }\n  else\n  {\nLABEL_7:\n    AutoSaveSettingsLayer::getBackupDirectory(lpFile);\n    v8 = (const CHAR *)lpFile;\n    if ( v17 > 0xF )\n      v8 = lpFile[0];\n    v9 = GetFileAttributesA(v8);\n    if ( v9 != -1 && (v9 & 0x10) != 0 )\n    {\n      v10 = (const CHAR *)lpFile;\n      if ( v17 > 0xF )\n        v10 = lpFile[0];\n      ShellExecuteA(nullptr, \"open\", v10, nullptr, nullptr, 10);\n    }\n    sub_14003D310((__int64)lpFile);\n  }\n  sub_14003D310((__int64)lpFileName);\n}", "assembly": "; \n; AutoSaveSettingsLayer::onOpenBackupDir from 0x14009c830 to 0x14009c9c3 (403 bytes)\n; \n; 2 xrefs:\n; > AutoSaveSettingsLayer::init @ 0x14009bc0a\n; > <???> @ 0x140912f20\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:26:05 +0000\n; \nmov     [rsp-8+arg_8], rbx                                             ; +0x0, 0x14009c830\nmov     [rsp-8+arg_10], rdi                                            ; +0x5, 0x14009c835\npush    rbp                                                            ; +0xa, 0x14009c83a\nlea     rbp, [rsp-57h]                                                 ; +0xb, 0x14009c83b\nsub     rsp, 0B0h                                                      ; +0x10, 0x14009c840\nmov     rax, cs:__security_cookie                                      ; +0x17, 0x14009c847\nxor     rax, rsp                                                       ; +0x1e, 0x14009c84e\nmov     [rbp+57h+var_10], rax                                          ; +0x21, 0x14009c851\nmov     rdi, rcx                                                       ; +0x25, 0x14009c855\nlea     rcx, [rbp+57h+lpFileName]                                      ; +0x28, 0x14009c858\ncall    AutoSaveSettingsLayer__getCustomBackupDirectory                ; +0x2c, 0x14009c85c\nnop                                                                    ; +0x31, 0x14009c861\ncmp     [rbp+57h+var_20], 0                                            ; +0x32, 0x14009c862\njz      loc_14009C93A                                                  ; +0x37, 0x14009c867\nlea     rcx, [rbp+57h+lpFileName]                                      ; +0x3d, 0x14009c86d\ncmp     [rbp+57h+var_18], 0Fh                                          ; +0x41, 0x14009c871\ncmova   rcx, [rbp+57h+lpFileName]; lpFileName                          ; +0x46, 0x14009c876\ncall    cs:GetFileAttributesA                                          ; +0x4b, 0x14009c87b\ncmp     eax, 0FFFFFFFFh                                                ; +0x51, 0x14009c881\njz      short loc_14009C88E                                            ; +0x54, 0x14009c884\ntest    al, 10h                                                        ; +0x56, 0x14009c886\njnz     loc_14009C93A                                                  ; +0x58, 0x14009c888\nlea     rax, [rbp+57h+var_80]                                          ; +0x5e, 0x14009c88e\nmov     [rbp+57h+var_60], rax                                          ; +0x62, 0x14009c892\nxorps   xmm0, xmm0                                                     ; +0x66, 0x14009c896\nmovups  [rbp+57h+var_80], xmm0                                         ; +0x69, 0x14009c899\nxor     eax, eax                                                       ; +0x6d, 0x14009c89d\nmov     [rbp+57h+var_70], rax                                          ; +0x6f, 0x14009c89f\nmov     [rbp+57h+var_68], 0Fh                                          ; +0x73, 0x14009c8a3\nmov     byte ptr [rbp+57h+var_80], al                                  ; +0x7b, 0x14009c8ab\nmovups  xmmword ptr [rbp+57h+lpFile], xmm0                             ; +0x7e, 0x14009c8ae\nmov     [rbp+57h+var_40], rax                                          ; +0x82, 0x14009c8b2\nmov     [rbp+57h+var_38], rax                                          ; +0x86, 0x14009c8b6\nmov     ecx, 20h ; ' '                                                 ; +0x8a, 0x14009c8ba\ncall    sub_14003D460                                                  ; +0x8f, 0x14009c8bf\nmov     [rbp+57h+lpFile], rax                                          ; +0x94, 0x14009c8c4\nmov     [rbp+57h+var_40], 13h                                          ; +0x98, 0x14009c8c8\nmov     [rbp+57h+var_38], 1Fh                                          ; +0xa0, 0x14009c8d0\nmovups  xmm0, cs:xmmword_14071BB98                                     ; +0xa8, 0x14009c8d8\nmovups  xmmword ptr [rax], xmm0                                        ; +0xaf, 0x14009c8df\nmovzx   ecx, cs:word_14071BBA8                                         ; +0xb2, 0x14009c8e2\nmov     [rax+10h], cx                                                  ; +0xb9, 0x14009c8e9\nmovzx   ecx, cs:byte_14071BBAA                                         ; +0xbd, 0x14009c8ed\nmov     [rax+12h], cl                                                  ; +0xc4, 0x14009c8f4\nmov     byte ptr [rax+13h], 0                                          ; +0xc7, 0x14009c8f7\nmov     rbx, [rdi]                                                     ; +0xcb, 0x14009c8fb\nlea     rax, [rbp+57h+var_80]                                          ; +0xce, 0x14009c8fe\nmov     [rsp+0B0h+lpDirectory], rax                                    ; +0xd2, 0x14009c902\nmov     r9d, 96h                                                       ; +0xd7, 0x14009c907\nmovss   xmm2, cs:dword_140834F64                                       ; +0xdd, 0x14009c90d\nmovss   xmm1, cs:dword_140834F20                                       ; +0xe5, 0x14009c915\nlea     rcx, [rbp+57h+lpFile]                                          ; +0xed, 0x14009c91d\ncall    TextAlertPopup__create                                         ; +0xf1, 0x14009c921\nmov     rdx, rax                                                       ; +0xf6, 0x14009c926\nmov     r8d, 64h ; 'd'                                                 ; +0xf9, 0x14009c929\nmov     rcx, rdi                                                       ; +0xff, 0x14009c92f\ncall    qword ptr [rbx+1C8h]                                           ; +0x102, 0x14009c932\njmp     short loc_14009C999                                            ; +0x108, 0x14009c938\nlea     rcx, [rbp+57h+lpFile]                                          ; +0x10a, 0x14009c93a\ncall    AutoSaveSettingsLayer__getBackupDirectory                      ; +0x10e, 0x14009c93e\nlea     rcx, [rbp+57h+lpFile]                                          ; +0x113, 0x14009c943\ncmp     [rbp+57h+var_38], 0Fh                                          ; +0x117, 0x14009c947\ncmova   rcx, [rbp+57h+lpFile]; lpFileName                              ; +0x11c, 0x14009c94c\ncall    cs:GetFileAttributesA                                          ; +0x121, 0x14009c951\ncmp     eax, 0FFFFFFFFh                                                ; +0x127, 0x14009c957\njz      short loc_14009C98F                                            ; +0x12a, 0x14009c95a\ntest    al, 10h                                                        ; +0x12c, 0x14009c95c\njz      short loc_14009C98F                                            ; +0x12e, 0x14009c95e\nlea     r8, [rbp+57h+lpFile]                                           ; +0x130, 0x14009c960\ncmp     [rbp+57h+var_38], 0Fh                                          ; +0x134, 0x14009c964\ncmova   r8, [rbp+57h+lpFile]; lpFile                                   ; +0x139, 0x14009c969\nmov     [rsp+0B0h+nShowCmd], 0Ah; nShowCmd                             ; +0x13e, 0x14009c96e\nxor     eax, eax                                                       ; +0x146, 0x14009c976\nmov     [rsp+0B0h+lpDirectory], rax; lpDirectory                       ; +0x148, 0x14009c978\nxor     r9d, r9d; lpParameters                                         ; +0x14d, 0x14009c97d\nlea     rdx, Operation; \"open\"                                         ; +0x150, 0x14009c980\nxor     ecx, ecx; hwnd                                                 ; +0x157, 0x14009c987\ncall    cs:ShellExecuteA                                               ; +0x159, 0x14009c989\nlea     rcx, [rbp+57h+lpFile]                                          ; +0x15f, 0x14009c98f\ncall    sub_14003D310                                                  ; +0x163, 0x14009c993\nnop                                                                    ; +0x168, 0x14009c998\nlea     rcx, [rbp+57h+lpFileName]                                      ; +0x169, 0x14009c999\ncall    sub_14003D310                                                  ; +0x16d, 0x14009c99d\nmov     rcx, [rbp+57h+var_10]                                          ; +0x172, 0x14009c9a2\nxor     rcx, rsp; StackCookie                                          ; +0x176, 0x14009c9a6\ncall    __security_check_cookie                                        ; +0x179, 0x14009c9a9\nlea     r11, [rsp+0B0h+var_s0]                                         ; +0x17e, 0x14009c9ae\nmov     rbx, [r11+18h]                                                 ; +0x186, 0x14009c9b6\nmov     rdi, [r11+20h]                                                 ; +0x18a, 0x14009c9ba\nmov     rsp, r11                                                       ; +0x18e, 0x14009c9be\npop     rbp                                                            ; +0x191, 0x14009c9c1\nretn                                                                   ; +0x192, 0x14009c9c2", "xrefs": ["AutoSaveSettingsLayer::init @ 0x14009bc0a", "<???> @ 0x140912f20"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}