Function at 0x4018f0
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 [0x403060]
test eax, eax
jne 0x401962
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov eax, dword [ebp - 0xdc]
mov ebx, dword [eax + 0x34]
push 0x4020d8
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 0x401942
mov ecx, eax
xchg dword [0x403060], ecx
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov eax, dword [ebp - 0xdc]
mov dword [eax + 0x34], ebx
mov eax, dword [0x403060]
push esi
call eax
add esp, 4
movzx eax, al
bt eax, edi
jae 0x401b6b
mov ecx, dword [0x4030ec]
mov eax, dword fs:[0x18]
mov dword [ebp - 0xdc], eax
mov edx, dword [ebp - 0xdc]
xor eax, eax
cmp ecx, dword [edx + 0x24]
je 0x401b70
lea ebx, [ebp - 0xdc]
test byte [0x40302d], 8
je 0x401a4b
mov eax, dword [0x403060]
test eax, eax
jne 0x401a04
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 0x4020d8
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 0x4019e7
mov ecx, eax
xchg dword [0x403060], 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 [0x403060]
push 0x40302d
call eax
add esp, 4
test al, 8
je 0x401a4b
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 [0x40303d], 8
je 0x401adf
mov eax, dword [0x403060]
test eax, eax
jne 0x401ab2
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 0x4020d8
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 0x401a95
mov ecx, eax
xchg dword [0x403060], 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 [0x403060]
push 0x40303d
call eax
add esp, 4
test al, 8
je 0x401adf
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 0x401b3e
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x401b3e
add ebx, eax
inc esi
mov eax, dword [edi*4 + 0x402074]
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 0x401b70
mov eax, 0xffffffff
add esp, 0xd0
pop esi
pop edi
pop ebx
pop ebp
ret