Function at 0x4792e0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4dfb50
mov eax, dword fs:[0]
push eax
sub esp, 0x28
mov eax, dword [0x5256a8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor esi, esi
mov ebx, ecx
cmp dword [eax + 0x10], esi
je 0x4794f5
push 0xffffffffffffffff
xor ecx, ecx
push esi
mov word [ebp - 0x2c], cx
push eax
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], esi
call fcn.00406690
mov dword [ebp - 4], esi
cmp dword [ebp - 0x1c], esi
je 0x4794a4
lea edx, [ebp - 0x2c]
push edx
mov eax, edx
push eax
call fcn.00416360
add esp, 8
test al, al
je 0x4794a4
mov eax, dword [ebp - 0x2c]
mov edi, 8
cmp dword [ebp - 0x18], edi
jae 0x47936a
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4794a9
push 1
push esi
push 0x4ffebc
lea ecx, [ebp - 0x2c]
call fcn.0040a0b0
cmp eax, 0xffffffff
jne 0x4794a9
push 1
push esi
push 0x4ffeb8
lea ecx, [ebp - 0x2c]
call fcn.0040a0b0
cmp eax, 0xffffffff
jne 0x4794a9
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x18], edi
jae 0x4793b6
lea eax, [ebp - 0x2c]
lea ecx, [ebp - 0x2c]
push ecx
push eax
call fcn.00416900
add esp, 8
test al, al
je 0x4794a9
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x18], edi
jae 0x4793d6
lea eax, [ebp - 0x2c]
push eax
call fcn.00416bb0
add esp, 4
test al, al
je 0x4794a9
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x18], edi
jae 0x4793f2
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x4794a9
lea edx, [ebp - 0x2c]
push edx
mov eax, edx
push eax
call fcn.00416c80
add esp, 8
test al, al
je 0x4794a9
lea ecx, [ebp - 0x2c]
push ecx
call fcn.00417940
add esp, 4
lea edi, [ebx + 0xcc]
push edi
mov dword [ebp - 0x34], edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebx + 0xe4]
mov byte [ebp - 4], 1
call fcn.00417ac0
mov eax, dword [ebp - 0x30]
cmp eax, dword [ebx + 0xe8]
je 0x4794dc
dec dword [eax + 0x28]
jne 0x4794c9
push eax
lea edx, [ebp - 0x30]
push edx
lea ecx, [ebx + 0xe4]
call fcn.004776f0
cmp dword [ebp - 0x18], 8
mov edx, dword [ebp - 0x2c]
jae 0x47947b
lea edx, [ebp - 0x2c]
mov ecx, dword [ebx + 0x14]
mov eax, dword [ecx + 0x14]
push edx
mov edx, dword [eax + 0x30]
add ecx, 0x14
push 1
push 0
call edx
test eax, eax
jne 0x4794b4
mov ecx, dword [ebx + 0x14]
mov eax, dword [ecx]
mov edx, dword [eax + 0x1c]
call edx
test al, al
je 0x4794b4
mov bl, 1
jmp 0x4794b6
mov edi, 8
cmp dword [ebp - 0x18], edi
jb 0x4794f5
mov edx, dword [ebp - 0x2c]
push edx
jmp 0x4794ed
xor bl, bl
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea ecx, [ebp - 0x2c]
call fcn.00409fe0
mov al, bl
jmp 0x4794f7
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea ecx, [ebp - 0x2c]
call fcn.00409fe0
mov al, 1
jmp 0x4794f7
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [ebp - 0x18], 8
jb 0x4794f5
mov eax, dword [ebp - 0x2c]
push eax
call fcn.00406cf9
add esp, 4
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00401306
mov esp, ebp
pop ebp
ret 4