Function at 0x4daf80
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4fbdb8
push eax
mov eax, 0x3f64
mov dword fs:[0], esp
call fcn.004ba380
push ebx
mov ebx, ecx
push esi
xor esi, esi
mov eax, dword [ebx + 0x62790]
push edi
cmp eax, esi
mov dword [ebp - 0x10], ebx
jne 0x4dafbe
or eax, 0xffffffff
jmp 0x4db5db
cmp dword [ebp + 8], esi
jne 0x4dafcb
or eax, 0xffffffff
jmp 0x4db5db
cmp dword [ebp + 0x14], esi
jne 0x4dafd8
or eax, 0xffffffff
jmp 0x4db5db
cmp dword [ebp + 0x18], 2
je 0x4dafeb
cmp dword [ebp + 0xc], esi
jne 0x4dafeb
or eax, 0xffffffff
jmp 0x4db5db
cmp dword [ebx + 0x620], esi
jne 0x4daffa
mov ecx, ebx
call fcn.004d0400
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x646]
mov word [ebp - 0x648], si
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x648]
push eax
push 0x50f4e4
push 0x103
push ecx
call dword [sym.imp.MSVCRT.dll__snwprintf]
mov ecx, 0x823
xor eax, eax
lea edi, [ebp - 0x3f6e]
mov word [ebp - 0x3f70], si
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebp + 0xc]
add esp, 0x10
cmp eax, esi
je 0x4db063
lea edx, [ebp - 0x3f70]
push 0x1047
push edx
push eax
mov ecx, ebx
call fcn.004daf50
cmp dword [ebx + 0x14], 2
jne 0x4db404
lea eax, [ebx + 0x6274c]
push eax
mov dword [ebp - 0x18], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 0x14], 1
lea eax, [ebp - 0x648]
mov dword [ebp - 4], esi
push eax
call fcn.004396d0
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x236]
mov word [ebp - 0x238], si
rep stosd dword es:[edi], eax
lea ecx, [ebp - 0x238]
add esp, 4
test ecx, ecx
stosw word es:[edi], ax
je 0x4db258
mov eax, dword [ebx + 0x14]
mov edi, 2
cmp eax, edi
jne 0x4db258
mov eax, dword [ebp + 0x14]
cmp eax, edi
jne 0x4db106
lea edx, [ebx + 0x3d0]
lea eax, [ebp - 0x238]
push edx
push 0x50f4e4
push 0x103
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
lea ecx, [ebp - 0x238]
push esi
push ecx
call fcn.004f1940
add esp, 0x18
jmp 0x4db258
push eax
mov ecx, ebx
call fcn.004d6380
cmp eax, 0xffffffff
je 0x4db258
mov edx, dword [ebx + 0x608]
lea eax, [eax + eax*4]
mov dword [ebp + 0xc], esi
lea eax, [eax + eax*4]
shl eax, 7
add eax, edx
cmp dword [eax + 4], edi
jne 0x4db137
mov dword [ebp + 0xc], 1
mov ebx, dword [eax]
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x84e]
mov word [ebp - 0x850], si
cmp ebx, 2
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
je 0x4db1e6
jmp 0x4db15e
xor esi, esi
mov ecx, dword [ebp - 0x10]
push ebx
call fcn.004d6380
cmp eax, 0xffffffff
je 0x4db255
mov edx, dword [ebp - 0x10]
lea eax, [eax + eax*4]
mov ecx, 0x81
mov edi, dword [edx + 0x608]
lea esi, [eax + eax*4]
shl esi, 7
add esi, edi
xor eax, eax
lea edi, [ebp - 0x43e]
mov ebx, dword [esi + 8]
mov word [ebp - 0x440], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edi, dword [sym.imp.MSVCRT.dll_swprintf]
lea eax, [ebp - 0x850]
push eax
lea ecx, [ebp - 0x440]
push 0x50f4e4
push ecx
call edi
add esp, 0xc
lea edx, [ebp - 0x440]
add esi, 0x48
lea eax, [ebp - 0x850]
push edx
push esi
push str._s_s
push eax
call edi
add esp, 0x10
cmp ebx, 2
jne 0x4db15c
xor esi, esi
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x43e]
mov word [ebp - 0x440], si
rep stosd dword es:[edi], eax
lea ecx, [ebp - 0x440]
push 0x104
push ecx
stosw word es:[edi], ax
call fcn.004dc910
lea edx, [ebp - 0x440]
push esi
push edx
call fcn.004f1940
mov eax, dword [ebp + 0xc]
add esp, 0x10
cmp eax, esi
lea eax, [ebp - 0x850]
lea ecx, [ebp - 0x440]
push eax
push ecx
je 0x4db23b
push 0x50f5ec
jmp 0x4db240
push str._s_s.url
lea edx, [ebp - 0x238]
push 0x103
push edx
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x14
mov ebx, dword [ebp - 0x10]
lea eax, [ebp - 0x238]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4db27b
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
or eax, 0xffffffff
jmp 0x4db5db
lea edx, [ebp - 0x238]
push 1
push edx
call fcn.004f1940
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x18de]
mov word [ebp - 0x18e0], si
rep stosd dword es:[edi], eax
add esp, 8
lea ecx, [ebp - 0x238]
stosw word es:[edi], ax
lea eax, [ebp - 0x648]
lea edx, [ebp - 0x18e0]
push eax
push ecx
push 0x50f5ec
push 0xff
push edx
call dword [sym.imp.MSVCRT.dll__snwprintf]
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x16d6]
mov word [ebp - 0x16d8], si
rep stosd dword es:[edi], eax
add esp, 0x14
lea ecx, [ebp - 0x16d8]
stosw word es:[edi], ax
lea eax, [ebp - 0x18e0]
push eax
push 0x50f4e4
push 0xfa
push ecx
call dword [sym.imp.MSVCRT.dll__snwprintf]
lea edx, [ebp - 0x16d8]
push str..url
push edx
call dword [sym.imp.MSVCRT.dll_wcscat]
mov ecx, 0x7f
xor eax, eax
lea edi, [ebp - 0x1ede]
mov word [ebp - 0x1ee0], si
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, 0x7f
xor eax, eax
lea edi, [ebp - 0x1ade]
mov word [ebp - 0x1ae0], si
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, 0x7f
xor eax, eax
lea edi, [ebp - 0x1cde]
mov word [ebp - 0x1ce0], si
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1ce0]
lea ecx, [ebp - 0x1ae0]
push eax
lea edx, [ebp - 0x1ee0]
push ecx
lea eax, [ebp - 0x20]
push edx
lea ecx, [ebp - 0x16d8]
push eax
push ecx
mov word [ebp - 0x20], si
mov dword [ebp - 0x1e], esi
call dword [sym.imp.MSVCRT.dll__wsplitpath]
add esp, 0x2c
lea edx, [ebp - 0x1ae0]
lea eax, [ebp - 0x648]
push edx
push 0x50f4e4
push eax
call dword [sym.imp.MSVCRT.dll_swprintf]
mov edi, dword [ebp + 0x18]
add esp, 0xc
mov ecx, edi
sub ecx, 2
neg ecx
sbb ecx, ecx
lea edx, [ebp - 0x18e0]
and ecx, 4
lea eax, [ebp - 0x3f70]
inc ecx
push ecx
push edx
push eax
mov ecx, ebx
call fcn.004d8280
test eax, eax
jne 0x4db3f3
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 0x14]
push edi
push ecx
push edx
mov ecx, ebx
call fcn.004d20a0
mov esi, eax
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x4db5d9
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 4], 0xffffffff
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, 0x28b
xor eax, eax
lea edi, [ebp - 0x1488]
xor edx, edx
rep stosd dword es:[edi], eax
mov ecx, 0x30e
lea edi, [ebp - 0x1488]
rep stosd dword es:[edi], eax
mov ecx, 0x30e
lea edi, [ebp - 0x1488]
rep stosd dword es:[edi], eax
mov ecx, dword [ebp + 0x18]
mov dword [ebp - 0x14a4], eax
mov dword [ebp - 0x14a0], eax
mov dword [ebp - 0x14b4], edx
mov dword [ebp - 0x149c], eax
mov dword [ebp - 0x14b0], edx
mov dword [ebp - 0x1498], eax
or eax, 0xffffffff
mov dword [ebp - 0x14cc], ecx
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x14d0], eax
mov dword [ebp - 0x148c], eax
mov dword [ebp - 0x1490], eax
mov dword [ebp - 0x1494], eax
mov dword [ebp - 0x14ac], edx
xor eax, eax
cmp ecx, esi
mov dword [ebp - 0x14a8], edx
mov edx, dword [ebp + 0x14]
lea ecx, [ebp - 0x30]
setne al
push ecx
mov dword [ebp - 0x14c4], 1
mov dword [ebp - 0x14b8], esi
mov dword [ebp - 0x14c8], edx
mov dword [ebp - 0x14bc], eax
mov dword [ebp - 0x14c0], esi
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
mov edx, dword [ebp - 0x28]
mov edi, dword [ebp - 0x24]
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x14ac], edx
mov dword [ebp - 0x149c], edx
mov edx, dword [ebp + 8]
mov dword [ebp - 0x14a8], edi
mov dword [ebp - 0x1498], edi
mov edi, dword [sym.imp.MSVCRT.dll_wcslen]
push edx
mov dword [ebp - 0x14b4], eax
mov dword [ebp - 0x14b0], ecx
mov dword [ebp - 0x14a4], eax
mov dword [ebp - 0x14a0], ecx
call edi
add esp, 4
cmp eax, 0x103
jbe 0x4db515
mov eax, 0x103
jmp 0x4db51e
mov eax, dword [ebp + 8]
push eax
call edi
add esp, 4
lea ecx, [ebp - 0x648]
lea edx, [ebp - 0x1488]
push ecx
push 0x50f4e4
push eax
push edx
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x10
cmp word [ebp - 0x3f70], si
je 0x4db5a8
lea eax, [ebp - 0x3f70]
test eax, eax
jne 0x4db552
xor edi, edi
jmp 0x4db58d
lea ecx, [ebp - 0x3f70]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
mov dword [ebp + 8], eax
add eax, 3
and al, 0xfc
call fcn.004ba380
mov edx, dword [ebp + 8]
mov edi, esp
push esi
push esi
push edx
push edi
lea eax, [ebp - 0x3f70]
push 0xffffffffffffffff
push eax
push esi
push esi
mov byte [edi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
push 0x510594
lea ecx, [ebp - 0x1280]
push 0x823
push ecx
call dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x10
lea edx, [ebp - 0x14d0]
push esi
push edx
mov ecx, ebx
call fcn.004d0c50
mov esi, eax
cmp esi, 0xffffffff
je 0x4db5d9
cmp dword [ebx + 0x14], 1
jne 0x4db5cd
mov ecx, ebx
call fcn.004cff10
jmp 0x4db5d9
mov eax, dword [ebp + 0x1c]
push esi
push eax
mov ecx, ebx
call fcn.004d8890
mov eax, esi
mov ecx, dword [ebp - 0xc]
lea esp, [ebp - 0x3f7c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18