Function at 0x40ae97
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
mov ebx, ecx
mov dword [ebp - 4], 0x40ae8c
push esi
xor esi, esi
mov dword [0x4260a4], esi
mov edx, dword [ebx]
push edi
lea ecx, [edx + 2]
mov ax, word [edx]
add edx, 2
cmp ax, si
jne 0x40aeb8
sub edx, ecx
mov ecx, dword [ebx]
sar edx, 1
mov dword [ebp - 0xc], edx
call fcn.00402c6f
mov edi, eax
push 0x3a
pop eax
mov dword [ebp - 0x14], eax
cmp word [edi], ax
je 0x418c5d
mov ecx, 0x250
call fcn.0040592e
push 0x5c
mov dword [ebx + 0x18], eax
movzx eax, word [edi]
pop ecx
mov dword [ebp - 0x10], ecx
cmp ax, cx
je 0x415906
mov edx, ecx
mov ecx, dword [ebx]
call fcn.00402580
mov esi, eax
test esi, esi
je 0x4151fa
add esi, 2
xor edi, edi
push 0x402c60
push esi
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
pop ecx
test eax, eax
je 0x41114b
push 0x402c64
push esi
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
pop ecx
test eax, eax
je 0x41114b
cmp dword [0x42602c], 4
je 0x4138e8
push dword [ebx]
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_GetFileAttributesW]
mov dword [ebp - 8], eax
cmp eax, 0xffffffff
jne 0x40b06a
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov dword [0x4260a4], eax
mov eax, dword [ebp - 8]
cmp eax, 0xffffffff
jne 0x40b075
mov edx, dword [ebx]
xor edi, edi
inc edi
mov ecx, edx
xor esi, esi
movzx eax, word [ecx]
test ax, ax
je 0x40afa0
cmp ax, word [ebp - 0x10]
je 0x40aff3
cmp ax, word [ebp - 0x14]
je 0x40aff7
add ecx, 2
inc edi
jmp 0x40af86
mov dword [ebx + 0xc], esi
test esi, esi
je 0x4151e9
xor eax, eax
cmp word [esi], ax
lea eax, [esi + 2]
je 0x4151f3
mov dword [ebx + 0x10], eax
push 0x2a
pop edx
mov ecx, esi
call fcn.004024b1
test eax, eax
je 0x40b082
or dword [ebx + 0x1c], 8
mov dword [0x426074], 1
push 0x2e
pop edx
mov ecx, esi
call fcn.004024b1
mov dword [ebx + 0x14], eax
xor eax, eax
pop edi
pop esi
inc eax
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, ecx
jmp 0x40af9a
cmp edi, 2
jne 0x40af9a
jmp 0x40aff3
mov dword [0x4260a4], edi
jmp 0x40af74
test al, 0x10
je 0x40af7d
jmp 0x41114b
push 0x3f
pop edx
mov ecx, esi
call fcn.004024b1
test eax, eax
je 0x40afdc
jmp 0x40afce
mov ecx, dword [ebx]
call fcn.00411191
test al, al
jne 0x41117e
mov edi, dword [ebp - 0xc]
mov esi, dword [ebx]
add edi, 5
lea ecx, [edi + edi]
call fcn.0040592e
push esi
mov edx, edi
mov dword [ebx], eax
mov ecx, eax
call fcn.00401da3
push dword [ebp - 4]
mov ecx, dword [ebx]
mov edx, edi
call fcn.00402c8a
mov eax, dword [ebx + 0x18]
mov dword [eax], 0x10
jmp 0x40af7d
cmp dword [0x426060], 1
je 0x40af52
cmp dword [0x426028], 1
jne 0x40af7d
mov dword [0x426028], edi
jmp 0x40af52
mov dword [ebx + 0x10], edx
mov esi, edx
jmp 0x40afbc
mov eax, esi
jmp 0x40afb9
mov esi, dword [ebx]
xor edi, edi
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x415203
sub ecx, edx
sar ecx, 1
cmp ecx, 2
jb 0x40af19
push 0x3a
pop eax
cmp word [esi + 2], ax
jne 0x40af19
jmp 0x418d1b
mov dword [ebp - 4], 0x40ae8e
jmp 0x41114b
cmp edx, 2
jle 0x40aee2
xor eax, eax
mov word [edi], ax
sub edi, 2
push esi
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_SetErrorMode]
push ecx
mov ecx, dword [ebx]
mov edx, 0x8000
mov dword [ebp - 8], eax
call fcn.0040480a
mov esi, eax
cmp esi, 0xffffffff
je 0x418cb8
mov ecx, esi
call fcn.004048d4
test eax, eax
jne 0x418ca2
mov ecx, esi
call fcn.00409837
test eax, eax
je 0x418cb8
mov ecx, esi
call fcn.004048d4
test eax, eax
jne 0x418d06
mov ecx, esi
call fcn.00409837
test eax, eax
jmp 0x418d04
add edi, 2
cmp dword [0x42602c], 4
push 0x3a
pop eax
mov word [edi], ax
jne 0x418cf0
cmp dword [0x426064], 0
jne 0x418ce4
push dword [ebx]
push 1
push 0x236b
call fcn.0040bd02
add esp, 0xc
mov dword [0x426068], 1
jmp 0x418d01
push dword [ebx]
push 1
push 0x236b
call fcn.0040bd02
add esp, 0xc
cmp esi, 0xffffffff
je 0x418d0d
mov ecx, esi
call fcn.004049f8
push dword [ebp - 8]
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_SetErrorMode]
jmp 0x40aee2
add esi, 4
jmp 0x40af19