Function at 0x4019f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0xd0
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov eax, dword [0x403040]
test eax, eax
jne 0x401a62
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov eax, dword [ebp - 0xdc]
mov ebx, dword [eax + 0x34]
push 0x40213c
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ecx, sym._fallback__wine_dbg_get_channel_flags
test eax, eax
je 0x401a42
mov ecx, eax
xchg dword [0x403040], ecx
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov eax, dword [ebp - 0xdc]
mov dword [eax + 0x34], ebx
mov eax, dword [0x403040]
push esi
call eax
add esp, 4
movzx eax, al
bt eax, edi
jae 0x401c6b
mov ecx, dword [0x4030cc]
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov edx, dword [ebp - 0xdc]
xor eax, eax
cmp ecx, dword [edx + 0x24]
je 0x401c70
lea ebx, [ebp - 0xdc]
test byte [0x403015], 8
je 0x401b4b
mov eax, dword [0x403040]
test eax, eax
jne 0x401b04
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0x14], eax
push 0x40213c
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ecx, sym._fallback__wine_dbg_get_channel_flags
test eax, eax
je 0x401ae7
mov ecx, eax
xchg dword [0x403040], ecx
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x14]
mov dword [eax + 0x34], ecx
mov eax, dword [0x403040]
push 0x403015
call eax
add esp, 4
test al, 8
je 0x401b4b
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 - 0xdc]
push ecx
push edx
push str._3u._03u:
push eax
call sym._sprintf
add esp, 0x10
lea ebx, [eax + ebp]
add ebx, 0xffffff24
test byte [0x403025], 8
je 0x401bdf
mov eax, dword [0x403040]
test eax, eax
jne 0x401bb2
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0x14], eax
push 0x40213c
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push str.__wine_dbg_get_channel_flags
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ecx, sym._fallback__wine_dbg_get_channel_flags
test eax, eax
je 0x401b95
mov ecx, eax
xchg dword [0x403040], ecx
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x14]
mov dword [eax + 0x34], ecx
mov eax, dword [0x403040]
push 0x403025
call eax
add esp, 4
test al, 8
je 0x401bdf
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
push dword [eax + 0x20]
push str._04x:
push ebx
call sym._sprintf
add esp, 0xc
add ebx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
push dword [eax + 0x24]
push str._04x:
push ebx
call sym._sprintf
add esp, 0xc
cmp edi, 3
ja 0x401c3e
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x401c3e
add ebx, eax
inc esi
mov eax, dword [edi*4 + 0x4020d8]
lea edx, [ebp - 0xdc]
sub edx, ebx
add edx, 0xc8
sub esp, 0x18
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], eax
mov dword [esp], ebx
mov dword [esp + 4], edx
call sym._snprintf
add esp, 0x18
push 2
call dword [sym.imp.ucrtbase.dll___acrt_iob_func]
add esp, 4
mov esi, eax
lea edi, [ebp - 0xdc]
push edi
call dword [sym.imp.ucrtbase.dll_strlen]
add esp, 4
push esi
push eax
push 1
push edi
call dword [sym.imp.ucrtbase.dll_fwrite]
add esp, 0x10
jmp 0x401c70
mov eax, 0xffffffff
add esp, 0xd0
pop esi
pop edi
pop ebx
pop ebp
ret