Function at 0x1464160
Capabilities:
Write file on windows

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x14
mov eax, dword [0x41f0cc]
mov edi, dword [esp + 0x28]
mov dword [esp + 0x10], eax
mov eax, dword [edi + 0x14]
test eax, eax
jle 0x145eb4f
xor esi, esi
mov eax, dword [edi + 0x18]
push 0x40214f
push dword [eax + esi*4]
call fcn.014287b5
add esp, 8
mov eax, dword [edi + 0x14]
inc esi
cmp esi, eax
jl 0x145eb34
test eax, eax
je 0x145eb95
xor ebx, ebx
cmp dword [0x41d7f8], 0
jne 0x145ed82
push 0xfffffffffffffff6
call dword [0x4863b4]
mov esi, eax
cmp esi, 0xffffffff
jne 0x145eb95
push 2
call fcn.0146a693
add esp, 4
xor esi, esi
inc esi
push eax
push esi
push 0x21
push 0x413235
call fcn.01475dc9
add esp, 0x10
push esi
call fcn.0145e680
mov eax, dword [edi + 8]
test eax, eax
je 0x145eba2
cmp dword [edi + 4], 0
jne 0x145ebb2
cmp dword [edi + 0xc], 0
jne 0x145ebb2
cmp dword [edi + 0x14], 0
je 0x145ed95
push 0xfffffffffffffff5
call dword [0x4863b4]
cmp eax, 0xffffffff
mov dword [esp], eax
je 0x145ed9a
mov eax, dword [edi + 8]
mov edi, dword [esp + 0x28]
test eax, eax
je 0x145ec18
mov ebp, dword [edi + 4]
test ebp, ebp
je 0x145ec18
push ebp
call fcn.01476c84
add esp, 4
mov ebx, eax
lea eax, [esp + 0xc]
push 0
push eax
push ebx
push ebp
push dword [esp + 0x10]
call dword [0x4864a8]
mov eax, dword [edi + 4]
cmp byte [eax + ebx - 1], 0xa
je 0x145ec18
push 0
lea eax, [esp + 0x10]
push eax
push 1
push 0x40407b
push dword [esp + 0x10]
call dword [0x4864a8]
mov ebp, dword [edi + 0xc]
test ebp, ebp
je 0x145ec5f
push ebp
call fcn.01476c84
add esp, 4
mov ebx, eax
lea eax, [esp + 0xc]
push 0
push eax
push ebx
push ebp
push dword [esp + 0x10]
call dword [0x4864a8]
mov eax, dword [edi + 0xc]
cmp byte [eax + ebx - 1], 0xa
je 0x145ec5f
push 0
lea eax, [esp + 0x10]
push eax
push 1
push 0x40407b
push dword [esp + 0x10]
call dword [0x4864a8]
xor ebx, ebx
mov eax, edi
inc ebx
cmp dword [edi + 0x14], 0
je 0x145ed82
xor ebx, ebx
xor ecx, ecx
mov eax, dword [eax + 0x18]
mov dword [esp + 4], ecx
mov ebp, dword [eax + ecx*4]
lea eax, [esp + 8]
push eax
push esi
call dword [0x486354]
mov eax, dword [esp + 8]
mov ecx, eax
and eax, 0xfffffff8
or ecx, 7
or eax, 3
cmp dword [ebp + 4], ebx
cmovne eax, ecx
push eax
push esi
call dword [0x48644c]
mov edi, dword [ebp]
push edi
call fcn.01476c84
add esp, 4
push ebx
lea ecx, [esp + 0x10]
push ecx
push eax
push edi
push dword [esp + 0x10]
call dword [0x4864a8]
xor edi, edi
jmp 0x145ecc9
mov edi, ecx
lea eax, [edi + edi*4]
mov dword [esp + 0xc], ebx
mov ecx, eax
sar ecx, 0x1f
shr ecx, 0x1e
add ecx, eax
sar ecx, 2
add ecx, 0x200
push ecx
push ebp
call fcn.0142873e
add esp, 8
mov eax, edi
mov ecx, dword [ebp + 8]
not eax
add eax, dword [ebp + 0xc]
add ecx, edi
push ebx
lea edx, [esp + 0x10]
push edx
push eax
push ecx
push esi
call dword [0x486440]
test eax, eax
je 0x145ed32
mov eax, dword [esp + 0xc]
test eax, eax
je 0x145ed32
mov edx, dword [ebp + 8]
lea ecx, [eax + edi]
cmp byte [edx + ecx - 1], 0xa
jne 0x145ecc7
cmp byte [edx + ecx - 2], 0xd
lea eax, [eax + edi - 1]
lea edi, [ecx - 2]
cmovne edi, eax
jmp 0x145ed35
xor edi, edi
dec edi
push dword [esp + 8]
push esi
call dword [0x48644c]
cmp dword [ebp + 4], 0
jne 0x145ed5e
push 0
lea eax, [esp + 0x10]
push eax
push 2
push 0x402dcd
push dword [esp + 0x10]
call dword [0x4864a8]
test edi, edi
js 0x145ed80
mov eax, dword [ebp + 8]
mov byte [eax + edi], 0
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 4]
inc ecx
cmp ecx, dword [eax + 0x14]
jb 0x145ec72
xor ebx, ebx
inc ebx
jmp 0x145ed82
xor ebx, ebx
mov ecx, dword [esp + 0x10]
call fcn.01466d40
mov eax, ebx
add esp, 0x14
pop esi
pop edi
pop ebx
pop ebp
ret
jmp 0x145ebc9
push 2
call fcn.0146a693
add esp, 4
xor esi, esi
inc esi
push eax
push esi
push 0x22
push 0x413257
call fcn.01475dc9
add esp, 0x10
push esi
call fcn.0145e680
int3
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [esp + 0xc]
call fcn.014252ca
add esp, 0xc
cmp eax, 0xffffffff
je 0x145eb17
ret