Function at 0x4a57a5
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x40
mov eax, dword [ebp + 8]
mov byte [ebp - 0x1c], al
cmp dword [ebp + 0x1c], 0
je 0x4a57cc
mov eax, dword [ebp + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x4a57cc
mov eax, dword [ebp + 0x1c]
mov eax, dword [eax]
mov dword [ebp - 0xc], eax
jmp 0x4a57d7
mov eax, dword [ebp + 0x10]
add eax, 0x94
mov dword [ebp - 0xc], eax
cmp dword [ebp + 0x20], 0
je 0x4a5899
cmp dword [ebp + 0x14], 0
je 0x4a581d
mov eax, dword [ebp + 0x14]
lea esi, [eax + 0x94]
movsx ebx, byte [ebp - 0x1c]
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0xc]
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], str._c_t_s:_s_t
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x4a5844
movsx ebx, byte [ebp - 0x1c]
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0xc]
mov dword [esp + 0xc], edx
mov dword [esp + 8], ebx
mov dword [esp + 4], str._c_t:_s_t
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
cmp dword [ebp + 0x18], 0
je 0x4a5875
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 8]
mov edx, dword [ebp + 0x18]
mov dword [esp + 0xc], edx
mov edx, dword [ebp + 0xc]
mov dword [esp + 8], edx
mov dword [esp + 4], str._s___s__n
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x4a59eb
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 8]
mov edx, dword [ebp + 0xc]
mov dword [esp + 8], edx
mov dword [esp + 4], 0x5b4a44
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x4a59eb
mov dword [ebp - 0x10], 0x5b4757
mov dword [ebp - 0x14], 0x5b4757
mov eax, dword [ebp + 0x10]
mov dword [esp], eax
call fcn.004a5568
test eax, eax
je 0x4a58d4
mov dword [esp], 1
call fcn.004a4536
mov dword [ebp - 0x10], eax
mov dword [esp], 0
call fcn.004a4536
mov dword [ebp - 0x14], eax
movsx ebx, byte [ebp - 0x1c]
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov edx, dword [ebp - 0x14]
mov dword [esp + 0x18], edx
mov edx, dword [ebp + 0xc]
mov dword [esp + 0x14], edx
mov edx, dword [ebp + 0x24]
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], ebx
mov edx, dword [ebp - 0x10]
mov dword [esp + 8], edx
mov dword [esp + 4], str.__s_c___s_s
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
cmp dword [ebp + 0x14], 0
je 0x4a5957
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call fcn.0045b587
mov esi, eax
mov eax, dword [ebp + 0x14]
add eax, 0x94
mov dword [esp], eax
call fcn.0045b587
mov ebx, eax
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], str._s_____s
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x4a5976
call sub.cygwin1.dll___getreent
mov ebx, dword [eax + 0xc]
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call fcn.0045b587
mov dword [esp + 4], ebx
mov dword [esp], eax
call sub.cygwin1.dll_fputs
cmp dword [ebp + 0x18], 0
je 0x4a59d3
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 2
mov dword [esp + 4], 1
mov dword [esp], 0x5b4a5f
call sub.cygwin1.dll_fwrite
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov dword [esp + 4], eax
mov eax, dword [ebp + 0x18]
mov dword [esp], eax
call sub.cygwin1.dll_fputs
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov dword [esp + 4], eax
mov dword [esp], 0x29
call sub.cygwin1.dll_fputc
call sub.cygwin1.dll___getreent
mov eax, dword [eax + 0xc]
mov dword [esp + 4], eax
mov dword [esp], 0xa
call sub.cygwin1.dll_fputc
nop
add esp, 0x40
pop ebx
pop esi
pop ebp
ret