Function at 0x1000e940
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0xcc
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov eax, dword [0x1003c570]
test eax, eax
jne 0x1000e999
mov edi, dword fs:[0x18]
mov ebx, dword [edi + 0x34]
push 0x100308ac
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
test eax, eax
mov ecx, dbg.fallback__wine_dbg_get_channel_flags
cmovne ecx, eax
mov eax, 0x1003c570
lock xchg dword [eax], ecx
mov dword [edi + 0x34], ebx
mov edi, dword [ebp + 8]
mov eax, dword [0x1003c570]
push esi
call eax
add esp, 4
movzx eax, al
bt eax, edi
jae 0x1000eb4f
mov ecx, dword [0x1003c5fc]
mov ebx, dword fs:[0x18]
xor eax, eax
cmp ecx, dword [ebx + 0x24]
je 0x1000eb54
lea edi, [ebp - 0xd8]
test byte [0x1003c0a1], 8
je 0x1000ea60
mov eax, dword [0x1003c570]
test eax, eax
jne 0x1000ea19
mov eax, dword [ebx + 0x34]
mov dword [ebp - 0x10], eax
push 0x100308ac
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
test eax, eax
mov ecx, dbg.fallback__wine_dbg_get_channel_flags
cmovne ecx, eax
mov eax, 0x1003c570
lock xchg dword [eax], ecx
mov eax, dword [ebp - 0x10]
mov dword [ebx + 0x34], eax
mov eax, dword [0x1003c570]
push 0x1003c0a1
call eax
add esp, 4
test al, 8
je 0x1000ea60
call dword [sym.imp.kernel32.dll_GetTickCount]
mov ecx, eax
mov edx, 0x10624dd3
mul edx
shr edx, 6
imul eax, edx, 0x3e8
sub ecx, eax
lea eax, [ebp - 0xd8]
push ecx
push edx
push str._3u._03u:
push eax
call dbg.sprintf
add esp, 0x10
lea edi, [eax + ebp]
add edi, 0xffffff28
test byte [0x1003c0b1], 8
je 0x1000eacd
mov eax, dword [0x1003c570]
test eax, eax
jne 0x1000eaac
mov eax, dword [ebx + 0x34]
mov dword [ebp - 0x10], eax
push 0x100308ac
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
test eax, eax
mov ecx, dbg.fallback__wine_dbg_get_channel_flags
cmovne ecx, eax
mov eax, 0x1003c570
lock xchg dword [eax], ecx
mov eax, dword [ebp - 0x10]
mov dword [ebx + 0x34], eax
mov eax, dword [0x1003c570]
push 0x1003c0b1
call eax
add esp, 4
test al, 8
je 0x1000eacd
push dword [ebx + 0x20]
push str._04x:
push edi
call dbg.sprintf
add esp, 0xc
add edi, eax
push dword [ebx + 0x24]
push str._04x:
push edi
call dbg.sprintf
add esp, 0xc
mov edx, dword [ebp + 8]
cmp edx, 3
ja 0x1000eb22
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1000eb22
add edi, eax
lea eax, [ebp - 0xd8]
sub eax, edi
add eax, 0xc8
mov edx, dword [edx*4 + 0x100308d0]
inc esi
sub esp, 0x18
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], edx
mov dword [esp], edi
mov dword [esp + 4], eax
call sym._snprintf
add esp, 0x18
lea edi, [ebp - 0xd8]
push edi
call dword [sym.imp.ucrtbase.dll_strlen]
add esp, 4
mov esi, eax
push 2
call dword [sym.imp.ucrtbase.dll___acrt_iob_func]
add esp, 4
push eax
push esi
push 1
push edi
call dword [sym.imp.ucrtbase.dll_fwrite]
add esp, 0x10
jmp 0x1000eb54
mov eax, 0xffffffff
add esp, 0xcc
pop esi
pop edi
pop ebx
pop ebp
ret