Function at 0x10001100
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x14]
push esi
push edi
xor edi, edi
push 2
push edi
push ebp
mov dword [esp + 0x28], edi
call dword [sym.imp.MSVCR90.dll_fseek]
add esp, 0xc
test eax, eax
je 0x10001126
xor esi, esi
jmp 0x10001139
push ebp
call dword [sym.imp.MSVCR90.dll_ftell]
push ebp
mov esi, eax
call dword [sym.imp.MSVCR90.dll_rewind]
add esp, 8
mov ebx, dword [sym.imp.MSVCR90.dll_fread]
push ebp
push 1
lea eax, [esp + 0x24]
push 4
push eax
mov dword [esp + 0x20], edi
call ebx
add esp, 0x10
cmp eax, 1
jne 0x1000132b
cmp dword [esp + 0x1c], 0x2454abcd
je 0x10001172
pop edi
pop esi
pop ebp
mov eax, 0xfffffffe
pop ebx
add esp, 8
ret
push ebp
push 1
lea ecx, [esp + 0x24]
push 4
push ecx
call ebx
add esp, 0x10
cmp eax, 1
jne 0x1000132b
mov eax, dword [esp + 0x1c]
cmp eax, 1
je 0x100011a9
cmp eax, 2
je 0x10001291
pop edi
pop esi
pop ebp
mov eax, 0xfffffffc
pop ebx
add esp, 8
ret
mov dword [esp + 0x14], edi
jmp 0x100011b6
mov ebx, dword [sym.imp.MSVCR90.dll_fread]
push ebp
push 1
lea edx, [esp + 0x24]
push 4
push edx
call ebx
add esp, 0x10
cmp eax, 1
jne 0x1000132b
mov eax, dword [esp + 0x1c]
push eax
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [esp + 0x20]
lea edx, [ecx + ecx]
push edx
mov ebx, eax
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
mov esi, eax
mov eax, dword [esp + 0x24]
push eax
push 0
push ebx
call sub.MSVCR90.dll_memset
mov ecx, dword [esp + 0x30]
lea edx, [ecx + ecx]
push edx
push 0
push esi
call sub.MSVCR90.dll_memset
mov eax, dword [esp + 0x3c]
push ebp
push eax
push 1
push ebx
call dword [sym.imp.MSVCR90.dll_fread]
mov ecx, dword [esp + 0x4c]
add esp, 0x30
cmp eax, ecx
jne 0x1000132b
mov eax, dword [esp + 0x14]
cmp eax, 3
ja case.default.0x1000122d
jmp dword [eax*4 + 0x10001338]
push 5
jmp 0x10001242
push 2
jmp 0x10001242
push 4
jmp 0x10001242
push 3
call fcn.10001350
mov edi, eax
add esp, 4
mov edx, dword [esp + 0x10]
mov ecx, dword [0x1000334c]
push edi
add ecx, edx
push esi
push ecx
call sub.MSVCR90.dll_memcpy
add dword [esp + 0x1c], edi
push ebx
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
push esi
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x28]
inc eax
add esp, 0x14
mov dword [esp + 0x14], eax
cmp eax, 4
jb 0x100011b0
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
push 0x400
add esi, 0xfffffff8
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov edi, eax
test esi, esi
jle 0x1000130d
push ebp
push 0x400
push 1
push edi
call ebx
add esp, 0x10
cmp esi, 0x400
jl 0x100012e4
cmp eax, 0x400
jne 0x10001322
mov ecx, dword [esp + 0x10]
push eax
mov eax, dword [0x1000334c]
add eax, ecx
push edi
push eax
call sub.MSVCR90.dll_memcpy
add esp, 0xc
add dword [esp + 0x10], 0x400
jmp 0x10001303
cmp eax, esi
jne 0x10001322
mov eax, dword [esp + 0x10]
mov edx, dword [0x1000334c]
push esi
add edx, eax
push edi
push edx
call sub.MSVCR90.dll_memcpy
add esp, 0xc
add dword [esp + 0x10], esi
sub esi, 0x400
test esi, esi
jg 0x100012a7
push edi
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x14]
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
push edi
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 0xffffff9c
pop ebx
add esp, 8
ret