Function at 0x4e8b10
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x3c
mov ebx, dword [ebp + 8]
mov dword [esp], ebx
call sub.msvcrt.dll_strlen
lea esi, [eax + 1]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], 8
mov dword [esp], 0xfde9
call sub.KERNEL32.dll_MultiByteToWideChar
sub esp, 0x18
mov edx, eax
test eax, eax
jle 0x4e8c50
mov ecx, 8
lea eax, [edx + edx + 0x1e]
and eax, 0xfffffff0
call fcn.005940a0
sub esp, eax
lea edi, [esp + 0x27]
and edi, 0xfffffff0
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], ecx
mov dword [esp], 0xfde9
call sub.KERNEL32.dll_MultiByteToWideChar
sub esp, 0x18
test eax, eax
jne 0x4e8c90
call sub.KERNEL32.dll_GetLastError
mov dword [esp + 0x10], 0xa9
mov dword [esp + 0xc], str.bss_file.c
mov dword [esp + 8], eax
mov dword [esp + 4], 1
mov dword [esp], 2
call fcn.004b26a0
mov dword [esp + 0x14], 0x5facb7
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0x5facba
mov dword [esp + 8], ebx
mov dword [esp + 4], str.fopen_
mov dword [esp], 5
call fcn.004b2e70
call sub.msvcrt.dll__errno
cmp dword [eax], 2
je 0x4e8d80
mov dword [esp + 0x10], 0xae
mov dword [esp + 0xc], str.bss_file.c
mov dword [esp + 8], 2
mov dword [esp + 4], 0x6d
mov dword [esp], 0x20
call fcn.004b26a0
xor ebx, ebx
mov eax, ebx
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x3ec
je 0x4e8d40
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x459
jne 0x4e8ba5
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], eax
mov dword [esp], ebx
call sub.msvcrt.dll_fopen
mov esi, eax
test eax, eax
jne 0x4e8ceb
jmp 0x4e8ba5
mov eax, dword [ebp + 0xc]
mov dword [esp], eax
call sub.msvcrt.dll_strlen
mov dword [esp + 0x14], 8
lea esi, [ebp - 0x28]
mov dword [esp + 0x10], esi
inc eax
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0xfde9
call sub.KERNEL32.dll_MultiByteToWideChar
sub esp, 0x18
test eax, eax
je 0x4e8ba5
mov dword [esp + 4], esi
mov dword [esp], edi
call sub.msvcrt.dll__wfopen
mov esi, eax
test eax, eax
je 0x4e8dcd
mov dword [esp], 0x59dc80
call fcn.004a8a70
mov ebx, eax
test eax, eax
je 0x4e8dc0
mov dword [esp + 4], 0x8000
mov dword [esp], eax
call fcn.004a8de0
mov dword [esp + 0xc], esi
mov dword [esp + 8], 1
mov dword [esp + 4], 0x6a
mov dword [esp], ebx
call fcn.004a9390
mov eax, ebx
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], 0
mov dword [esp], 0xfde9
call sub.KERNEL32.dll_MultiByteToWideChar
sub esp, 0x18
mov edx, eax
test eax, eax
jle 0x4e8c60
xor ecx, ecx
jmp 0x4e8b65
mov dword [esp + 0x10], 0xac
mov dword [esp + 0xc], str.bss_file.c
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], 0x6d
mov dword [esp], 0x20
call fcn.004b26a0
xor ebx, ebx
jmp 0x4e8c3d
mov dword [esp], esi
call sub.msvcrt.dll_fclose
jmp 0x4e8c3d
call sub.msvcrt.dll__errno
cmp dword [eax], 2
je 0x4e8c70
call sub.msvcrt.dll__errno
cmp dword [eax], 9
jne 0x4e8ba5
jmp 0x4e8c70