Function at 0x4124c0
Capabilities:
Check if file exists

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x41e7ab
push eax
mov eax, 0x295c
mov dword fs:[0], esp
call fcn.0041ae80
mov eax, dword [0x4256f0]
push ebp
push esi
mov esi, 1
cmp eax, esi
mov ebp, ecx
jne 0x412510
lea eax, [esp + 0x34]
lea ecx, [ebp + 0x1018]
push eax
push ecx
call sub.MSVCRT.dll__stati64
add esp, 8
test eax, eax
je 0x41252c
xor eax, eax
jmp 0x412978
lea edx, [esp + 0x34]
lea eax, [ebp + 0x18]
push edx
push eax
call sub.MSVCRT.dll__wstati64
add esp, 8
test eax, eax
je 0x41252c
xor eax, eax
jmp 0x412978
mov eax, dword [esp + 0x2984]
push ebx
xor ebx, ebx
push edi
cmp eax, ebx
mov dword [esp + 0x10], ebx
je 0x41273d
lea ecx, [esp + 0x196c]
push eax
push ecx
call sub.MSVCRT.dll_wcscpy
lea edi, [ebp + 0x18]
lea edx, [esp + 0x974]
push edi
push edx
call sub.MSVCRT.dll_wcscpy
add esp, 0x10
lea eax, [esp + 0x96c]
mov ecx, ebp
push eax
call fcn.0040f6e0
lea ecx, [esp + 0x96c]
lea edx, [esp + 0x196c]
push ecx
push edx
call sub.MSVCRT.dll_wcscat
mov edx, dword [0x4256f0]
add esp, 8
xor eax, eax
cmp edx, esi
sete al
push eax
lea ecx, [esp + 0x2c]
call fcn.00401f60
lea ecx, [esp + 0x196c]
mov dword [esp + 0x2974], ebx
push ecx
push SysReAllocString
lea ecx, [esp + 0x30]
call fcn.00401fb0
cmp eax, esi
jne 0x41271f
lea edx, [esp + 0x14]
mov ebx, 0x420
push edx
push 0x423e10
lea ecx, [esp + 0x30]
mov dword [esp + 0x1c], ebx
call fcn.00402230
mov esi, eax
test esi, esi
je 0x41270f
cmp dword [esp + 0x14], ebx
jne 0x412706
mov eax, dword [esp + 0x58]
mov ebx, dword [esp + 0x54]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x60]
cdq
push esi
push edi
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], edx
call sub.MSVCRT.dll__wcsicmp
add esp, 8
test eax, eax
jne 0x412706
mov ecx, dword [esi + 0x208]
cmp ecx, ebx
jne 0x412706
mov edx, dword [esi + 0x20c]
mov eax, dword [esp + 0x24]
cmp edx, eax
jne 0x412706
mov eax, dword [esi + 0x210]
mov ecx, dword [esp + 0x18]
cmp eax, ecx
jne 0x412706
mov ecx, dword [esi + 0x214]
mov eax, dword [esp + 0x1c]
cmp ecx, eax
jne 0x412706
mov eax, dword [esp + 0x2988]
lea edx, [esi + 0x218]
push edx
push eax
call sub.MSVCRT.dll_wcscpy
mov eax, dword [0x4256f0]
add esp, 8
cmp eax, 1
jne 0x4126b6
push 0
push 0
lea ecx, [esp + 0x74]
push 0x104
push ecx
lea edx, [ebp + 0x1824]
push 0xffffffffffffffff
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x6c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
jmp 0x4126c3
lea ecx, [ebp + 0x1824]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x412706
mov eax, dword [esp + 0x2984]
mov edx, dword [esi + 0x208]
mov dword [eax], edx
mov ecx, dword [esi + 0x20c]
mov dword [eax + 4], ecx
mov eax, dword [esp + 0x2980]
mov edx, dword [esi + 0x210]
mov dword [eax], edx
mov ecx, dword [esi + 0x214]
mov dword [eax + 4], ecx
mov eax, 1
mov dword [esp + 0x10], eax
mov dword [ebp + 0x1a2c], eax
push esi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
lea ecx, [esp + 0x28]
call fcn.00402080
xor ebx, ebx
mov esi, 1
lea ecx, [esp + 0x28]
mov dword [esp + 0x2974], 0xffffffff
call fcn.00401fa0
cmp dword [esp + 0x10], ebx
jne 0x412972
cmp dword [0x4256f0], esi
jne 0x412880
lea edx, [esp + 0x56c]
lea eax, [esp + 0x76c]
push edx
lea ecx, [esp + 0x270]
push eax
lea edx, [esp + 0x1c]
push ecx
lea eax, [ebp + 0x1018]
push edx
push eax
call sub.MSVCRT.dll__splitpath
lea edi, [esp + 0x280]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x14
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edx, ecx
sub edx, 2
js 0x412972
cmp byte [esp + edx + 0x26c], 0x5c
je 0x4127a3
dec edx
jns 0x412791
jmp 0x412972
cmp edx, 0xffffffff
je 0x412972
lea edi, [esp + 0x26c]
or ecx, 0xffffffff
xor eax, eax
lea esi, [esp + 0x36c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov dword [esp + 0x18], esi
mov eax, ecx
mov esi, edi
mov edi, dword [esp + 0x18]
push 0x423df8
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x423dfc
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
mov byte [esp + edx + 0x371], 0
sub edi, ecx
lea edx, [esp + 0x370]
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x770]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x374]
lea edx, [esp + 0x1c]
push ecx
lea eax, [esp + 0x78]
push edx
push eax
call sub.MSVCRT.dll__makepath
mov ecx, dword [esp + 0x299c]
add esp, 0x14
lea edi, [esp + 0x6c]
xor eax, eax
push 2
push ecx
or ecx, 0xffffffff
lea edx, [esp + 0x74]
repne scasb al, byte es:[edi]
not ecx
push ecx
push edx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea eax, [esp + 0x6c]
mov dword [ebp + 0x1a2c], ebx
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x412972
jmp 0x412945
lea eax, [esp + 0x36c]
lea ecx, [esp + 0x76c]
push eax
lea edx, [esp + 0x70]
push ecx
lea eax, [esp + 0x20]
push edx
lea ecx, [ebp + 0x18]
push eax
push ecx
call sub.MSVCRT.dll__wsplitpath
lea edx, [esp + 0x80]
push edx
call sub.MSVCRT.dll_wcslen
mov esi, eax
add esp, 0x18
sub esi, 2
js 0x412972
lea eax, [esp + esi*2 + 0x6c]
cmp word [eax], 0x5c
je 0x4128d5
dec esi
sub eax, 2
cmp esi, ebx
jge 0x4128c2
jmp 0x412972
cmp esi, 0xffffffff
je 0x412972
lea eax, [esp + 0x6c]
lea ecx, [esp + 0x56c]
push eax
push ecx
call sub.MSVCRT.dll_wcscpy
lea edx, [esp + 0x574]
push 0x423de8
push edx
mov word [esp + esi*2 + 0x57e], bx
call sub.MSVCRT.dll_wcscat
mov esi, dword [esp + 0x2998]
lea eax, [esp + 0x77c]
push 0x423de0
lea ecx, [esp + 0x580]
push eax
lea edx, [esp + 0x30]
push ecx
push edx
push esi
call sub.MSVCRT.dll__wmakepath
add esp, 0x24
mov dword [ebp + 0x1a2c], ebx
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x412972
mov eax, dword [esp + 0x2984]
mov ecx, dword [esp + 0x54]
mov edx, dword [esp + 0x58]
mov dword [esp + 0x10], 1
mov dword [eax], ecx
mov ecx, dword [esp + 0x2980]
mov dword [eax + 4], edx
mov eax, dword [esp + 0x60]
cdq
mov dword [ecx], eax
mov dword [ecx + 4], edx
mov eax, dword [esp + 0x10]
pop edi
pop ebx
mov ecx, dword [esp + 0x2964]
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x2968
ret 0x14