Function at 0x4f6ce0
Capabilities:
Read file on windows
Write file on windows

Disassembly:
sub esp, 0x18
mov eax, dword [esp + 0x20]
push ebx
mov ebx, dword [esp + 0x3c]
push ebp
push esi
mov ecx, eax
and eax, 0xfffffdff
push edi
xor edi, edi
and ecx, 0x200
cmp eax, 0x18
mov esi, 1
mov dword [esp + 0x18], esi
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], edi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x30], eax
jne 0x4f6e51
cmp dword [0x631490], edi
jne 0x4f6e51
mov eax, dword [esp + 0x2c]
cmp eax, 0xa
jne 0x4f6d5a
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x3c]
push ebx
push eax
mov eax, dword [esp + 0x40]
push ecx
push edx
push eax
call fcn.004f5f80
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
xor ecx, ecx
cmp eax, 0xb
mov eax, dword [0x631438]
sete cl
add ecx, eax
jne 0x4f6dea
push 0x620ad0
call fcn.004e70c0
add esp, 4
push 0x86c
push str.C:4017_buildmysql_4.0.17innobaseosos0file.c
call sub.KERNEL32.dll_GetCurrentThreadId
push eax
call fcn.004d1950
add esp, 4
push eax
push str.__InnoDB:_Assertion_failure_in_thread__lu_in_file__s_line__lu_n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_Failing_assertion:_type__OS_FILE_WRITE
push 0x620ad0
call fcn.00599e71
push str._nInnoDB:_We_intentionally_generate_a_memory_trap._n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_Send_a_detailed_bug_report_to_mysql_lists.mysql.com_n
push 0x620ad0
call fcn.00599e71
mov edx, dword [0x631440]
mov dword [0x63143c], esi
mov eax, dword [edx]
add esp, 0x2c
cmp eax, edi
je 0x4f6df2
mov dword [0x631440], edi
jmp 0x4f6df2
cmp dword [0x63143c], edi
je 0x4f6e27
push 0x86c
push str.C:4017_buildmysql_4.0.17innobaseosos0file.c
call sub.KERNEL32.dll_GetCurrentThreadId
push eax
call fcn.004d1950
add esp, 4
push eax
push str.InnoDB:_Thread__lu_stopped_in_file__s_line__lu_n
push 0x620ad0
call fcn.00599e71
push 0x3b9aca00
call fcn.004e7040
add esp, 0x18
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x3c]
push ebx
push eax
mov eax, dword [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x40]
push edx
push eax
push ecx
call fcn.004f61d0
add esp, 0x18
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
mov ebx, dword [esp + 0x38]
mov ebp, dword [esp + 0x2c]
cmp eax, 0x15
jne 0x4f6e79
cmp ebp, 0xa
jne 0x4f6e6e
mov edi, dword [0x63149c]
jmp 0x4f6f16
mov edi, dword [0x6314a0]
jmp 0x4f6f16
cmp eax, 0x16
jne 0x4f6e8d
mov dword [esp + 0x14], edi
mov edi, dword [0x6314a4]
jmp 0x4f6f16
cmp eax, 0x17
jne 0x4f6e9a
mov edi, dword [0x6314a8]
jmp 0x4f6f16
cmp eax, 0x18
jne 0x4f6ea7
mov edi, dword [0x6314ac]
jmp 0x4f6f16
push 0x620ad0
call fcn.004e70c0
add esp, 4
push 0x887
push str.C:4017_buildmysql_4.0.17innobaseosos0file.c
call sub.KERNEL32.dll_GetCurrentThreadId
push eax
call fcn.004d1950
add esp, 4
push eax
push str.__InnoDB:_Assertion_failure_in_thread__lu_in_file__s_line__lu_n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_We_intentionally_generate_a_memory_trap._n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_Send_a_detailed_bug_report_to_mysql_lists.mysql.com_n
push 0x620ad0
call fcn.00599e71
mov edx, dword [0x631440]
mov dword [0x63143c], esi
mov eax, dword [edx]
push eax
push 0x5f45ec
call fcn.0059a00d
add esp, 0x2c
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x44]
mov eax, dword [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x40]
push edx
mov edx, dword [esp + 0x3c]
push eax
mov eax, dword [esp + 0x5c]
push ecx
mov ecx, dword [esp + 0x5c]
push edx
push ebx
push eax
push ecx
push edi
push ebp
call fcn.004f7280
add esp, 0x28
cmp ebp, 0xa
mov esi, eax
jne 0x4f6fb5
mov eax, dword [0x631490]
test eax, eax
je 0x4f6f94
mov edx, dword [esp + 0x10]
mov eax, dword [0x6314b8]
mov ecx, dword [0x6314b4]
add eax, edx
mov edx, dword [esp + 0x48]
inc ecx
mov dword [0x6314b8], eax
lea eax, [esi + 0x3c]
push eax
mov eax, dword [esp + 0x40]
mov dword [0x6314b4], ecx
lea ecx, [esp + 0x14]
push ecx
push edx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [esp + 0x18], eax
jmp 0x4f7061
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x4f709d
push esi
push edi
call fcn.004f7130
push eax
call fcn.004f6aa0
add esp, 0xc
jmp 0x4f7061
cmp ebp, 0xb
jne 0x4f6fee
mov eax, dword [0x631490]
test eax, eax
je 0x4f6f94
mov eax, dword [0x6314bc]
inc eax
lea ecx, [esi + 0x3c]
push ecx
mov ecx, dword [esp + 0x40]
lea edx, [esp + 0x14]
push edx
mov dword [0x6314bc], eax
mov eax, dword [esp + 0x50]
push eax
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [esp + 0x18], eax
jmp 0x4f7061
push 0x620ad0
call fcn.004e70c0
add esp, 4
push 0x8b1
push str.C:4017_buildmysql_4.0.17innobaseosos0file.c
call sub.KERNEL32.dll_GetCurrentThreadId
push eax
call fcn.004d1950
add esp, 4
push eax
push str.__InnoDB:_Assertion_failure_in_thread__lu_in_file__s_line__lu_n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_We_intentionally_generate_a_memory_trap._n
push 0x620ad0
call fcn.00599e71
push str.InnoDB:_Send_a_detailed_bug_report_to_mysql_lists.mysql.com_n
push 0x620ad0
call fcn.00599e71
mov edx, dword [0x631440]
mov dword [0x63143c], 1
mov eax, dword [edx]
push eax
push 0x5f45ec
call fcn.0059a00d
add esp, 0x2c
mov eax, dword [0x631490]
test eax, eax
je 0x4f709d
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4f7086
mov ecx, dword [esp + 0x48]
cmp dword [esp + 0x10], ecx
je 0x4f70e1
mov dword [esp + 0x1c], 1
jmp 0x4f70a5
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
je 0x4f70e1
mov dword [esp + 0x1c], 1
jmp 0x4f70a5
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4f710d
push esi
push edi
call fcn.004f73b0
add esp, 8
cmp ebp, 0xa
mov eax, str.aio_read
je 0x4f70be
mov eax, str.aio_write
mov edx, dword [esp + 0x34]
push eax
push edx
push ebx
call fcn.004f5640
add esp, 0xc
test eax, eax
je 0x4f711a
mov eax, dword [esp + 0x30]
xor edi, edi
mov esi, 1
jmp 0x4f6e59
cmp dword [esp + 0x30], 0x18
jne 0x4f710d
lea eax, [esp + 0x2c]
push eax
mov eax, dword [esi + 4]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x2c]
push edx
push eax
push 0xffffffffffffffff
call fcn.004f7420
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x18
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret