Function at 0x539350
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x6f405c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, ecx
mov dword [ebp - 0x208], edi
test edi, edi
jne 0x539388
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0059e593
mov esp, ebp
pop ebp
ret 4
push 0x5ca6a0
push edi
call fcn.0059ebe1
lea edx, [esi + 0x2e]
add esp, 8
mov dword [esi + 4], eax
mov eax, edi
sub edx, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x5393a0
mov eax, dword [esi + 4]
test eax, eax
je 0x539374
push ebx
push 2
push 0
push eax
call fcn.005a2f54
mov eax, dword [esi + 4]
push eax
call fcn.005a329c
mov ecx, dword [esi + 4]
push 0
push 0
push ecx
mov dword [ebp - 0x20c], eax
call fcn.005a2f54
add esp, 0x1c
mov ecx, esi
call fcn.005387f0
mov edx, dword [esi + 4]
push edx
push 1
lea edi, [esi + 0x18]
push 0xc
push edi
call fcn.0059ef2b
mov eax, dword [edi]
sub eax, dword [esi + 0x1c]
add esp, 0x10
sub eax, dword [esi + 0x20]
lea ecx, [esi + 0x144]
push eax
call fcn.005975d0
test eax, eax
jne 0x53945e
push eax
push 0x38
push str.MHFile.cpp
call fcn.0053e8b0
mov ecx, dword [ebp - 0x208]
push ecx
lea edx, [ebp - 0x104]
push str.Bin_File_Version_Error_____s
push edx
call fcn.0059ec3f
add esp, 0x18
push 0
push 0
lea eax, [ebp - 0x104]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop ebx
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0059e593
mov esp, ebp
pop ebp
ret 4
lea ecx, [esi + 0x144]
call fcn.00597580
test eax, eax
je 0x53951c
mov edi, dword [ebp - 0x20c]
add edi, 0xfffffff2
push edi
call fcn.0059daa8
add esp, 4
mov dword [esi + 0x26], eax
test eax, eax
jne 0x53949c
push eax
push 0x49
push str.MHFile.cpp
call fcn.0053e8b0
add esp, 0xc
jmp 0x539449
push edi
push 0
push eax
call fcn.0059e5b0
mov ecx, dword [esi + 0x1c]
mov edx, dword [esi + 0x26]
mov eax, dword [esi + 4]
add esp, 0xc
push ecx
push edi
push edx
push eax
lea ecx, [esi + 0x144]
call fcn.00597990
test eax, eax
jne 0x5394ee
mov ecx, dword [ebp - 0x208]
push ecx
lea edx, [ebp - 0x204]
push str.File_Open_Error_:__s
push edx
call fcn.0059ec3f
add esp, 0xc
push 0
push 0
lea eax, [ebp - 0x204]
jmp 0x539440
mov ecx, dword [esi + 4]
push ecx
call fcn.0059e8e0
add esp, 4
pop ebx
mov eax, 1
pop edi
mov dword [esi + 4], 0
mov dword [esi + 0x2a], eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0059e593
mov esp, ebp
pop ebp
ret 4
mov edx, dword [esi + 4]
push edx
push 1
lea eax, [esi + 0x24]
push 1
push eax
call fcn.0059ef2b
mov eax, dword [esi + 0x20]
add esp, 0x10
test eax, eax
je 0x539553
push eax
call fcn.0059daa8
mov ecx, dword [esi + 4]
mov edx, dword [esi + 0x20]
push ecx
push edx
push 1
push eax
mov dword [esi + 0x26], eax
call fcn.0059ef2b
add esp, 0x14
mov eax, dword [esi + 4]
push eax
push 1
lea ecx, [esi + 0x25]
push 1
push ecx
call fcn.0059ef2b
mov edx, dword [esi + 4]
push edx
call fcn.0059e8e0
add esp, 0x14
mov ecx, esi
mov dword [esi + 4], 0
call fcn.00538ca0
test eax, eax
je 0x539449
call fcn.005387b0
test eax, eax
je 0x539449
mov ecx, dword [ebp - 4]
pop ebx
mov eax, 1
pop edi
mov dword [esi + 0x2a], eax
xor ecx, ebp
pop esi
call fcn.0059e593
mov esp, ebp
pop ebp
ret 4