Function at 0x419cc8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
mov esi, ecx
push edi
cmp dword [esi + 4], 2
je 0x419ce3
cmp dword [esi + 4], 3
jne 0x419fcf
cmp dword [ebp + 8], 0
je 0x419fcf
mov ebx, dword [ebp + 0x10]
test ebx, ebx
je 0x419fcf
cmp dword [esi + 0xc], 0xffffffff
jne 0x419d20
mov eax, dword [esi + 0x4c]
push dword [esi + 4]
mov edi, dword [esi + 0x48]
mov dword [ebp - 8], eax
mov eax, dword [esi]
call dword [eax + 0x34]
test eax, eax
jne 0x419fd2
mov eax, dword [ebp - 8]
mov dword [esi + 0x48], edi
mov dword [esi + 0x4c], eax
xor edi, edi
cmp dword [esi + 0x18], edi
jne 0x419d48
mov ecx, 0x5f9088
call fcn.0041a2ec
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], edi
mov dword [esi + 0x20], edi
mov dword [esi + 0x24], edi
mov dword [esi + 0x28], edi
test eax, eax
jne 0x419d48
or dword [esi + 8], 0xffffffff
push edi
push dword [esi + 0x38]
push dword [esi + 0x4c]
push dword [esi + 0x48]
call fcn.00552cd0
push edi
push dword [esi + 0x38]
push edx
push eax
call fcn.00552e90
push 0
mov edi, edx
push edi
push eax
push dword [esi + 0xc]
mov ecx, esi
mov dword [ebp - 4], eax
mov dword [ebp - 8], edi
call fcn.0041a1e8
cmp eax, dword [ebp - 4]
jne 0x41a098
cmp edx, edi
jne 0x41a098
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x419ede
push 0
push dword [esi + 0x38]
push dword [esi + 0x4c]
push dword [esi + 0x48]
call fcn.00552ed0
test edx, edx
jl 0x419ede
jg 0x419db6
test eax, eax
je 0x419ede
mov eax, dword [esi + 0x48]
xor edx, edx
div dword [esi + 0x38]
and dword [ebp + 0xc], 0
push 0
lea eax, [ebp + 0xc]
push eax
push dword [esi + 0x38]
mov ecx, esi
push dword [esi + 0x18]
push dword [esi + 0xc]
mov dword [ebp - 0xc], edx
call fcn.0041a171
test eax, eax
jne 0x419e0d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov edx, eax
mov dword [esi + 8], edx
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push edx
push 0x2a0
mov eax, dword [ecx]
push str.CPortableUnBufWinPFile.cpp
call dword [eax + 4]
jmp 0x41a0bb
mov edx, dword [ebp - 0xc]
mov eax, dword [esi + 0x38]
sub eax, edx
cmp edi, eax
mov ecx, edi
cmova ecx, eax
mov eax, dword [esi + 0x18]
push ecx
push dword [ebp + 8]
add eax, edx
push eax
mov dword [ebp - 0xc], ecx
call fcn.0054fca0
add esp, 0xc
mov ecx, esi
push 0
push dword [ebp - 8]
push dword [ebp - 4]
push dword [esi + 0xc]
call fcn.0041a1e8
cmp eax, dword [ebp - 4]
jne 0x419eba
cmp edx, dword [ebp - 8]
jne 0x419eba
push 0
lea eax, [ebp + 0xc]
push eax
push dword [esi + 0x38]
push dword [esi + 0x18]
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x419e8a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov edx, eax
mov dword [esi + 8], edx
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push edx
push 0x2c2
jmp 0x419dfe
mov eax, dword [ebp - 0xc]
add dword [ebx], eax
mov ecx, dword [ebp + 8]
add ecx, eax
sub edi, eax
add dword [esi + 0x48], eax
mov eax, dword [esi + 0x48]
mov dword [ebp + 8], ecx
adc dword [esi + 0x4c], 0
mov edx, dword [esi + 0x4c]
cmp edx, dword [esi + 0x34]
jl 0x419ee1
jg 0x419eb2
cmp eax, dword [esi + 0x30]
jbe 0x419ee1
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], edx
jmp 0x419ee1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov edx, eax
mov dword [esi + 8], edx
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push edx
push 0x2b5
jmp 0x419dfe
mov ecx, dword [ebp + 8]
cmp edi, dword [esi + 0x38]
jb 0x419f58
xor edx, edx
mov eax, edi
div dword [esi + 0x38]
mov ebx, eax
imul ebx, dword [esi + 0x38]
cmp ebx, dword [esi + 0x3c]
cmova ebx, dword [esi + 0x3c]
push ebx
push ecx
push dword [esi + 0x18]
call fcn.0054fca0
and dword [ebp - 0xc], 0
add esp, 0xc
lea eax, [ebp - 0xc]
push 0
push eax
push ebx
push dword [esi + 0x18]
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x419fa0
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 8]
add dword [eax], ebx
add ecx, ebx
sub edi, ebx
add dword [esi + 0x48], ebx
mov eax, dword [esi + 0x48]
mov dword [ebp + 8], ecx
adc dword [esi + 0x4c], 0
mov edx, dword [esi + 0x4c]
cmp edx, dword [esi + 0x34]
jl 0x419f50
jg 0x419f4a
cmp eax, dword [esi + 0x30]
jbe 0x419f50
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], edx
cmp edi, dword [esi + 0x38]
jae 0x419ee6
mov ebx, dword [ebp + 0x10]
test edi, edi
je 0x41a076
and dword [ebp + 0x10], 0
push 0
lea eax, [ebp + 0x10]
push eax
push dword [esi + 0x38]
mov ecx, esi
push dword [esi + 0x18]
push dword [esi + 0xc]
call fcn.0041a171
test eax, eax
jne 0x419fd9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov dword [esi + 8], eax
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push eax
push 0x311
jmp 0x41a0b1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov edx, eax
mov dword [esi + 8], edx
test ecx, ecx
je 0x419fc5
push dword [esi + 0x10]
mov eax, dword [ecx]
push edx
push 0x2eb
push str.CPortableUnBufWinPFile.cpp
call dword [eax + 4]
cmp dword [esi + 8], 0
jne 0x41a0bb
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret 0xc
push edi
push dword [ebp + 8]
push dword [esi + 0x18]
call fcn.0054fca0
add esp, 0xc
mov ecx, esi
push 0
push dword [esi + 0x4c]
push dword [esi + 0x48]
push dword [esi + 0xc]
call fcn.0041a1e8
cmp eax, dword [esi + 0x48]
jne 0x41a07d
cmp edx, dword [esi + 0x4c]
jne 0x41a07d
push 0
lea eax, [ebp + 0x10]
push eax
push dword [esi + 0x38]
push dword [esi + 0x18]
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x41a042
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov dword [esi + 8], eax
test ecx, ecx
je 0x419fc5
push dword [esi + 0x10]
mov edx, dword [ecx]
push eax
push 0x32f
push str.CPortableUnBufWinPFile.cpp
call dword [edx + 4]
jmp 0x419fc5
add dword [ebx], edi
add dword [esi + 0x48], edi
mov eax, dword [esi + 0x48]
adc dword [esi + 0x4c], 0
mov ecx, dword [esi + 0x4c]
cmp ecx, dword [esi + 0x34]
jl 0x41a063
jg 0x41a05d
cmp eax, dword [esi + 0x30]
jbe 0x41a063
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], ecx
mov eax, dword [esi]
lea ecx, [ebp - 0x10]
xorps xmm0, xmm0
push ecx
mov ecx, esi
movlpd qword [ebp - 0x10], xmm0
call dword [eax + 0x24]
xor eax, eax
jmp 0x419fd2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov dword [esi + 8], eax
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push eax
push 0x323
jmp 0x41a0b1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x14]
mov dword [esi + 8], eax
test ecx, ecx
je 0x41a0bb
push dword [esi + 0x10]
push eax
push 0x277
mov edx, dword [ecx]
push str.CPortableUnBufWinPFile.cpp
call dword [edx + 4]
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x10]
jmp 0x419fd2