Function at 0x401380
Capabilities:
Check if file exists
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xf8c
mov eax, dword [0x4c33d0]
xor eax, esp
mov dword [esp + 0xf88], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
xor eax, eax
push 0x206
push eax
mov word [esp + 0x368], ax
lea eax, [esp + 0x36a]
push eax
mov dword [0x4c9788], edi
call sub.MSVCR110.dll_memset
add esp, 0xc
xor eax, eax
push 0x206
push eax
mov word [esp + 0xb88], ax
lea eax, [esp + 0xb8a]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
lea eax, [esp + 0xb80]
push eax
push 0
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
jne 0x401430
push str.isafe_
lea eax, [esp + 0xb84]
push eax
lea eax, [esp + 0x368]
push eax
call ebx
push str.logiSafeTray.log
lea eax, [esp + 0x364]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
lea eax, [esp + 0x360]
push eax
push 0
push 0xffffffffffffffff
call dword [sym.imp.isafepxy.dll_ISAFE_InitProgramLogEx]
add esp, 0xc
cmp dword [0x4c38e0], 0
je 0x401481
push str.OpenLinkURL
push 0xffffffffffffffff
call dword [sym.imp.isafepxy.dll_ISAFE_WriteProgramLogString]
add esp, 8
cmp dword [0x4c38e4], 8
mov ecx, 0x4c38d0
cmovae ecx, dword [0x4c38d0]
call fcn.0045a530
call dword [sym.imp.isafepxy.dll_ISAFE_CloseProgramLog]
jmp 0x40183e
call fcn.00401320
test eax, eax
je 0x401476
mov esi, dword [sym.imp.isafepxy.dll_ISAFE_WriteProgramLogString]
push str.GlobalInit
push 0xffffffffffffffff
call esi
mov eax, dword [0x4c9770]
add esp, 8
test al, 1
jne 0x4014ba
or eax, 1
push 0x488dc0
mov dword [0x4c9770], eax
call fcn.0047ce4d
add esp, 4
push edi
mov ecx, 0x4c9360
call fcn.0045a590
mov eax, dword [0x4c935c]
test al, 1
jne 0x4014e8
or eax, 1
mov dword [0x4c935c], eax
call fcn.0045a420
push 0x488db0
call fcn.0047ce4d
add esp, 4
push 5
push str.iSafe
mov ecx, 0x4c9344
call fcn.00401d60
lea ecx, [esp + 0x28]
call fcn.0043afd0
xor eax, eax
push 0x206
push eax
mov word [esp + 0xd90], ax
lea eax, [esp + 0xd92]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
cmp dword [esp + 0x3c], 8
lea eax, [esp + 0x28]
cmovae eax, dword [esp + 0x28]
push str.skin2_tray_style_style.xml
push eax
lea eax, [esp + 0xd90]
push eax
call ebx
xor eax, eax
push 0x206
push eax
mov word [esp + 0x980], ax
lea eax, [esp + 0x982]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
cmp dword [esp + 0x3c], 8
lea eax, [esp + 0x28]
cmovae eax, dword [esp + 0x28]
push str.skin2_trayimage_resource.xml
push eax
lea eax, [esp + 0x980]
push eax
call ebx
xor eax, eax
push 0x206
push eax
mov word [esp + 0x160], ax
lea eax, [esp + 0x162]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
cmp dword [esp + 0x3c], 8
lea eax, [esp + 0x28]
cmovae eax, dword [esp + 0x28]
push str.lang_tray_lang.xml
push eax
lea eax, [esp + 0x160]
push eax
call ebx
xor eax, eax
push 0x206
push eax
mov word [esp + 0x778], ax
lea eax, [esp + 0x77a]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
cmp dword [esp + 0x3c], 8
lea eax, [esp + 0x28]
cmovae eax, dword [esp + 0x28]
push str.skin2_traylayoutmsgbox.xml
push eax
lea eax, [esp + 0x778]
push eax
call ebx
push 0
lea eax, [esp + 0x774]
push eax
push 0
lea eax, [esp + 0x984]
push eax
lea eax, [esp + 0xd98]
push eax
push edi
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::COUIManager____cdecl_OUI::COUIManager::GetUIManager_void_]
mov ecx, eax
call dword [sym.imp.ouilibx.dll_public:_bool___thiscall_OUI::COUIManager::Initialize_struct_HINSTANCE_____wchar_t___wchar_t___wchar_t___wchar_t___bool_]
movzx eax, al
push eax
push str.Initialize_OUI:__d
push 0xffffffffffffffff
call dword [sym.imp.isafepxy.dll_ISAFE_WriteProgramLog]
add esp, 0xc
lea ecx, [esp + 0x10]
push 0x48fcb8
call fcn.00401e60
lea ecx, [esp + 0x10]
call fcn.0043a890
cmp dword [esp + 0x24], 8
mov edi, eax
jb 0x401666
push dword [esp + 0x10]
call dword [sym.imp.MSVCR110.dll_void___cdecl_operator_delete_void__]
add esp, 4
test edi, edi
jne 0x401675
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLCID]
movzx edi, ax
jmp 0x401678
movzx edi, di
mov eax, dword [0x4c9778]
test al, 1
jne 0x401696
or eax, 1
push 0x488dd0
mov dword [0x4c9778], eax
call fcn.0047ce4d
add esp, 4
movzx eax, di
push eax
call fcn.0045af50
mov dword [esp + 0xc], eax
push eax
lea eax, [esp + 0x15c]
push eax
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::OSTRING_TABLE____cdecl_OUI::OSTRING_TABLE::GetStringTable_void_]
mov edi, dword [sym.imp.ouilibx.dll_public:_bool___thiscall_OUI::OSTRING_TABLE::UpdateStringTableXML_wchar_t_const___wchar_t_const__]
mov ecx, eax
call edi
test al, al
jne 0x401712
push dword [esp + 0xc]
push str.Failed_to_find_system_language:__s
push 0xffffffffffffffff
call dword [sym.imp.isafepxy.dll_ISAFE_WriteProgramLog]
add esp, 0xc
lea eax, [esp + 0x158]
push 0x48fac0
push eax
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::OSTRING_TABLE____cdecl_OUI::OSTRING_TABLE::GetStringTable_void_]
mov ecx, eax
call edi
test al, al
jne 0x401712
push str.Failed_to_find_default_language:_en_us
push 0xffffffffffffffff
call esi
add esp, 8
lea eax, [esp + 0x158]
push 0x48fb20
push eax
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::OSTRING_TABLE____cdecl_OUI::OSTRING_TABLE::GetStringTable_void_]
mov ecx, eax
call edi
push str.UpdateStringTableXML
push 0xffffffffffffffff
call esi
xor eax, eax
push 0x206
push eax
mov word [esp + 0x578], ax
lea eax, [esp + 0x57a]
push eax
call sub.MSVCR110.dll_memset
add esp, 0x14
cmp dword [esp + 0x3c], 8
lea eax, [esp + 0x28]
cmovae eax, dword [esp + 0x28]
push str.skin2_traylayout_traydlg.xml
push eax
lea eax, [esp + 0x570]
push eax
call ebx
lea eax, [esp + 0x568]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x401777
push str.Failed_to_find_traydlg_UI_config
push 0xffffffffffffffff
call esi
add esp, 8
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::OGLOBAL_DATA____cdecl_OUI::OGLOBAL_DATA::GetGlobalData_void_]
mov dword [eax + 0x20], 0xfed8b3
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::OGLOBAL_DATA____cdecl_OUI::OGLOBAL_DATA::GetGlobalData_void_]
mov dword [eax + 0x24], 0xfcc897
call fcn.004666b0
push ecx
lea eax, [esp + 0x56c]
push eax
push ecx
lea ecx, [esp + 0x4c]
call fcn.004296f0
lea eax, [esp + 0x40]
mov ecx, eax
mov dword [0x4c9784], eax
call dword [sym.imp.ouilibx.dll_public_virtual:_int___thiscall_OUI::COVDialog::DoModal_void_]
mov dword [0x4c9784], 0
call dword [sym.imp.ouilibx.dll_public:_static_class_OUI::COUIManager____cdecl_OUI::COUIManager::GetUIManager_void_]
mov edx, dword [eax]
mov ecx, eax
call dword [edx]
push str.Uninitialize_OUI
push 0xffffffffffffffff
call esi
add esp, 8
cmp dword [0x4c9bd4], 0
je 0x4017ff
mov eax, dword [0x4c97bc]
test eax, eax
je 0x4017f5
push eax
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov dword [0x4c9bd4], 0
mov eax, dword [0x4c9780]
test eax, eax
je 0x40180f
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str.GlobalClean
push 0xffffffffffffffff
call esi
add esp, 8
call dword [sym.imp.isafepxy.dll_ISAFE_CloseProgramLog]
lea ecx, [esp + 0x40]
call fcn.00429840
cmp dword [esp + 0x3c], 8
jb 0x40183e
push dword [esp + 0x28]
call dword [sym.imp.MSVCR110.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov ecx, dword [esp + 0xf94]
pop edi
pop esi
pop ebx
xor ecx, esp
xor eax, eax
call fcn.0047cd06
mov esp, ebp
pop ebp
ret 0x10