Function at 0x402c90
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4087e8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xc
push ebx
push ebp
push esi
push edi
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x2c]
xor esi, esi
push 0x40c16c
push eax
mov dword [esp + 0x2c], esi
call dword [sym.imp.MSVCRT.dll_fopen]
mov edi, eax
add esp, 8
cmp edi, esi
jne 0x402ceb
lea ecx, [esp + 0x30]
push 0x40a208
push ecx
mov dword [esp + 0x38], 3
call sub.MSVCRT.dll__CxxThrowException
mov ebx, dword [sym.imp.MSVCRT.dll_fread]
push edi
push 2
lea edx, [esp + 0x18]
push 1
push edx
call ebx
add esp, 0x10
test eax, eax
jne 0x402d1b
lea eax, [esp + 0x30]
push 0x40a208
push eax
mov dword [esp + 0x38], 7
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [esp + 0x10]
cmp ax, si
jne 0x402d3b
lea ecx, [esp + 0x30]
push 0x40a208
push ecx
mov dword [esp + 0x38], 7
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [esp + 0x30]
and eax, 0xffff
push eax
call fcn.00407c70
test eax, eax
jne 0x402d61
lea edx, [esp + 0x30]
push 0x40a208
push edx
mov dword [esp + 0x38], esi
call sub.MSVCRT.dll__CxxThrowException
cmp word [esp + 0x10], si
mov dword [esp + 0x14], esi
jb 0x402e52
mov dword [esp + 0x2c], esi
mov eax, dword [esp + 0x30]
mov ebp, dword [esp + 0x2c]
push edi
push 2
mov esi, dword [eax + 8]
push 1
add esi, ebp
push esi
call ebx
mov eax, dword [edi + 0xc]
add esp, 0x10
test al, 0x10
jne 0x402e7e
test al, 0x20
jne 0x402e95
push edi
lea ebp, [esi + 2]
push 2
push 1
push ebp
call ebx
mov eax, dword [edi + 0xc]
add esp, 0x10
test al, 0x10
jne 0x402eac
test al, 0x20
jne 0x402ec3
mov ax, word [ebp]
test ax, ax
jbe 0x402e13
and eax, 0xffff
inc eax
push eax
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esi + 0xc], eax
test eax, eax
je 0x402eda
xor ecx, ecx
push edi
mov cx, word [ebp]
push 1
push ecx
push eax
call ebx
mov eax, dword [esi + 0xc]
xor edx, edx
mov dx, word [ebp]
add esp, 0x10
mov byte [edx + eax], 0
mov eax, dword [edi + 0xc]
test al, 0x10
jne 0x402ef1
test al, 0x20
jne 0x402f08
push edi
push 4
add esi, 8
push 1
push esi
call ebx
mov al, byte [edi + 0xc]
add esp, 0x10
test al, 0x20
jne 0x402f1f
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov ebp, dword [esp + 0x2c]
inc eax
and ecx, 0xffff
add ebp, 0x10
cmp eax, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x2c], ebp
jle 0x402d74
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
mov al, byte [edi + 0xc]
add esp, 4
test al, 0x10
je 0x402f36
lea ecx, [esp + 0x30]
push 0x40a208
push ecx
mov dword [esp + 0x38], 6
call sub.MSVCRT.dll__CxxThrowException
lea edx, [esp + 0x30]
push 0x40a208
push edx
mov dword [esp + 0x38], 1
call sub.MSVCRT.dll__CxxThrowException
lea eax, [esp + 0x30]
push 0x40a208
push eax
mov dword [esp + 0x38], 4
call sub.MSVCRT.dll__CxxThrowException
lea ecx, [esp + 0x30]
push 0x40a208
push ecx
mov dword [esp + 0x38], 1
call sub.MSVCRT.dll__CxxThrowException
lea edx, [esp + 0x30]
push 0x40a208
push edx
mov dword [esp + 0x38], 4
call sub.MSVCRT.dll__CxxThrowException
lea eax, [esp + 0x30]
push 0x40a208
push eax
mov dword [esp + 0x38], 0
call sub.MSVCRT.dll__CxxThrowException
lea ecx, [esp + 0x30]
push 0x40a208
push ecx
mov dword [esp + 0x38], 1
call sub.MSVCRT.dll__CxxThrowException
lea edx, [esp + 0x30]
push 0x40a208
push edx
mov dword [esp + 0x38], 4
call sub.MSVCRT.dll__CxxThrowException
lea eax, [esp + 0x30]
push 0x40a208
push eax
mov dword [esp + 0x38], 4
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [esp + 0x30]
mov dx, word [esp + 0x10]
lea ecx, [esp + 0x18]
mov dword [esp + 0x24], 0xffffffff
mov word [eax + 4], dx
call fcn.00407f86
mov ecx, dword [esp + 0x1c]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x18
ret 8