Function at 0x401380
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x6c
mov eax, dword [0x42d008]
xor eax, esp
mov dword [esp + 0x68], eax
push ebx
push esi
mov esi, dword [esp + 0x78]
push edi
mov eax, dword [esi]
test eax, eax
jne 0x4013b6
lea eax, [esi + 0x68]
push 0x421220
push eax
call fcn.004027d0
add esp, 8
mov dword [esi], eax
test eax, eax
je 0x4015a4
push 0
push 0
push eax
mov dword [esp + 0x1c], 0
call fcn.00409f09
push dword [esi]
lea eax, [esp + 0x1c]
push 2
push 1
push eax
call fcn.00409b12
mov ax, word [esp + 0x28]
add esp, 0x1c
cmp al, 0x4d
jne 0x40147f
cmp ah, 0x5a
jne 0x40147f
push 0
push 0x3c
push dword [esi]
call fcn.00409f09
push dword [esi]
lea eax, [esp + 0x20]
push 1
push 4
push eax
call fcn.00409b12
mov eax, dword [esp + 0x2c]
push 0
add eax, 0x18
push eax
push dword [esi]
call fcn.00409f09
push dword [esi]
lea eax, [esp + 0x38]
push 1
push 2
push eax
call fcn.00409b12
mov ax, word [esp + 0x44]
add esp, 0x38
cmp al, 0xb
jne 0x40147f
cmp ah, 1
jne 0x401445
mov ecx, 0x98
jmp 0x40144f
cmp ah, 2
jne 0x40147f
mov ecx, 0xa8
mov eax, dword [esp + 0x10]
push 0
add eax, ecx
push eax
push dword [esi]
call fcn.00409f09
push dword [esi]
lea eax, [esp + 0x20]
push 1
push 4
push eax
call fcn.00409b12
mov eax, dword [esp + 0x2c]
add esp, 0x1c
test eax, eax
je 0x40147f
cmp eax, 1
jge 0x401494
push 2
push 0
push dword [esi]
call fcn.00409f09
push dword [esi]
call fcn.0040a51c
add esp, 0x10
lea ebx, [eax - 0x60]
push 0
push ebx
push dword [esi]
lea edi, [esp + 0x28]
call fcn.00409f09
add esp, 0xc
test eax, eax
jne 0x4015a4
push dword [esi]
lea eax, [esp + 0x18]
push 1
push 0x60
push eax
call fcn.00409b12
add esp, 0x10
cmp eax, 1
jb 0x4015a4
nop dword [eax]
push 8
push edi
push str.MEI_f_v_n_v
call fcn.00409730
add esp, 0xc
test eax, eax
je 0x401502
dec edi
lea eax, [esp + 0x14]
cmp edi, eax
jae 0x4014d0
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x68]
xor ecx, esp
call fcn.00407830
add esp, 0x6c
ret
movups xmm0, xmmword [edi]
movups xmmword [esi + 0x10], xmm0
movups xmm0, xmmword [edi + 0x10]
movups xmmword [esi + 0x20], xmm0
movups xmm0, xmmword [edi + 0x20]
movups xmmword [esi + 0x30], xmm0
movups xmm0, xmmword [edi + 0x30]
movups xmmword [esi + 0x40], xmm0
movups xmm0, xmmword [edi + 0x40]
movups xmmword [esi + 0x50], xmm0
movq xmm0, qword [edi + 0x50]
movq qword [esi + 0x60], xmm0
push dword [esi + 0x18]
call sub.WS2_32.dll_ntohl
push dword [esi + 0x24]
lea ecx, [esp + 0x18]
mov dword [esi + 0x406c], 0
sub edi, ecx
add edi, ebx
sub edi, eax
add edi, 0x58
mov dword [esi + 4], edi
call sub.WS2_32.dll_ntohl
push 0
mov dword [0x42da64], eax
push dword [esi + 0x1c]
call sub.WS2_32.dll_ntohl
add eax, dword [esi + 4]
push eax
push dword [esi]
call fcn.00409f09
add esp, 0xc
push dword [esi + 0x20]
call sub.WS2_32.dll_ntohl
push eax
call fcn.004097ce
add esp, 4
mov dword [esi + 8], eax
test eax, eax
jne 0x4015b9
push str.Could_not_allocate_buffer_for_TOC.
push str.malloc
call fcn.00401760
add esp, 8
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x68]
xor ecx, esp
call fcn.00407830
add esp, 0x6c
ret
push dword [esi]
push 1
push dword [esi + 0x20]
call sub.WS2_32.dll_ntohl
push eax
push dword [esi + 8]
call fcn.00409b12
add esp, 0x10
cmp eax, 1
jae 0x4015e2
push str.Could_not_read_from_file.
push str.fread
jmp 0x40159c
push dword [esi + 0x20]
call sub.WS2_32.dll_ntohl
add eax, dword [esi + 8]
push dword [esi]
mov dword [esi + 0xc], eax
call fcn.00409900
add esp, 4
test eax, eax
je 0x401620
push str.Error_on_file_n.
call fcn.004018c0
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x68]
xor ecx, esp
call fcn.00407830
add esp, 0x6c
ret
push esi
call fcn.00401030
mov ecx, dword [esp + 0x78]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00407830
add esp, 0x6c
ret