Function at 0x4606f0
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x58da50
mov eax, dword fs:[0]
push eax
sub esp, 0x12c
mov eax, dword [0x5f4760]
xor eax, esp
mov dword [esp + 0x128], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x5f4760]
xor eax, esp
push eax
lea eax, [esp + 0x140]
mov dword fs:[0], eax
push 0x603ce8
mov esi, ecx
mov dword [esp + 0x34], 0x603ce8
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [esp + 0x148], 0
mov eax, dword [0x603d14]
mov eax, dword [eax]
mov ebx, dword [0x603d00]
mov ebp, eax
lea ebx, [ebx]
mov edi, dword [0x603d14]
test ebx, ebx
je 0x460772
cmp ebx, dword [0x603d00]
je 0x460777
call fcn.004a35f3
cmp ebp, edi
je 0x4607f2
mov edi, dword [esi]
test ebx, ebx
jne 0x4607b7
call fcn.004a35f3
xor eax, eax
cmp ebp, dword [eax + 0x14]
jne 0x460792
call fcn.004a35f3
mov eax, dword [ebp + 8]
mov ecx, edi
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x4607bb
test dl, dl
je 0x4607b3
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x4607bb
add eax, 2
add ecx, 2
test dl, dl
jne 0x460797
xor eax, eax
jmp 0x4607c0
mov eax, dword [ebx]
jmp 0x460788
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x4607e2
test ebx, ebx
jne 0x4607de
call fcn.004a35f3
xor eax, eax
cmp ebp, dword [eax + 0x14]
jne 0x4607d9
call fcn.004a35f3
mov ebp, dword [ebp]
jmp 0x460760
mov eax, dword [ebx]
jmp 0x4607cf
push ebp
push ebx
lea ebx, [esp + 0x1c]
mov edi, 0x603d00
call fcn.00460db0
mov edx, dword [0x5ff398]
mov eax, dword [edx + 0xc]
mov ecx, 0x5ff398
call eax
lea ebp, [eax + 0x10]
mov dword [esp + 0x1c], ebp
mov bl, 3
mov byte [esp + 0x148], bl
mov ecx, dword [0x603dfc]
push 0x103
push ecx
lea edx, [esp + 0x3c]
push edx
call fcn.004a5b40
mov eax, dword [esi]
add esp, 0xc
push eax
lea eax, [esp + 0x38]
push eax
mov byte [esp + 0x13f], 0
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
lea ecx, [esp + 0x34]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x460923
lea edx, [esp + 0x14]
push edx
lea ecx, [esp + 0x38]
call fcn.00402fe0
mov byte [esp + 0x148], 4
lea edi, [esp + 0x14]
call fcn.00460160
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], edx
mov byte [esp + 0x148], bl
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4608a2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esi]
lea eax, [ecx - 0x10]
lea esi, [ebp - 0x10]
cmp eax, esi
je 0x4608f4
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x4608e3
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x4608e3
call fcn.004066f0
mov ebp, eax
or eax, 0xffffffff
lock xadd dword [edi], eax
dec eax
test eax, eax
jg 0x4608da
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
add ebp, 0x10
mov dword [esp + 0x1c], ebp
jmp 0x4608f4
mov edi, dword [ecx - 0xc]
push ecx
lea eax, [esp + 0x20]
call fcn.004033b0
mov ebp, dword [esp + 0x1c]
mov eax, dword [0x603d14]
mov edx, dword [eax + 4]
lea edi, [eax + 4]
lea ecx, [esp + 0x1c]
push ecx
push edx
push eax
call fcn.00460f60
mov ecx, 1
mov edx, 0x603d00
mov esi, eax
call fcn.00461010
mov dword [edi], esi
mov eax, dword [esi + 4]
mov dword [eax], esi
mov byte [esp + 0x148], 0
lea eax, [ebp - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x460947
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x148], 0xffffffff
push 0x603ce8
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [esp + 0x140]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x128]
xor ecx, esp
call fcn.004a314d
add esp, 0x138
ret