Function at 0x4cf2d0
Capabilities:
Get disk size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x4c
mov eax, dword [0x57b070]
xor eax, esp
mov dword [esp + 0x48], eax
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, ecx
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x4cf4b0
test esi, esi
jle 0x4cf4b0
mov eax, dword [edi + 0x1c]
cmp eax, 0xffffffff
jne 0x4cf34a
mov dword [edi], 0x556b90
call fcn.004df100
push 0xd9
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
add edi, 4
add esp, 0xc
cmp dword [edi + 0x14], 8
jb 0x4cf337
mov edi, dword [edi]
push edi
push str.hFile_is_invalid__filename:_s_r_n
call fcn.004df180
add esp, 8
jmp 0x4cf543
push 0
lea edx, [esp + 0x14]
mov dword [esp + 0x14], 0
push edx
push esi
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4cf44c
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], 0x556e5c
call ebx
mov dword [esp + 0x14], eax
cmp eax, 0x70
jne 0x4cf416
lea eax, [esp + 0x28]
xorps xmm0, xmm0
push eax
lea eax, [esp + 0x24]
movq qword [esp + 0x1c], xmm0
push eax
lea eax, [esp + 0x20]
movq qword [esp + 0x28], xmm0
push eax
push 0x556e68
movq qword [esp + 0x38], xmm0
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
test eax, eax
je 0x4cf3eb
call fcn.004df100
push 0xe9
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
push dword [esp + 0x28]
push dword [esp + 0x28]
push esi
push 0x70
push str.write_file_err__errcode:_d__writesize:_d__FreeBytesAvailable:_I64d_r_n
call fcn.004df180
add esp, 0x20
jmp 0x4cf416
call ebx
mov esi, eax
call fcn.004df100
push 0xee
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
push esi
push str.GetDiskFreeSpaceEx_err__errcode:_d_r_n
call fcn.004df180
add esp, 0x14
call fcn.004df100
push 0xf1
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
add edi, 4
add esp, 0xc
cmp dword [edi + 0x14], 8
jb 0x4cf43d
mov edi, dword [edi]
push edi
push dword [esp + 0x18]
push str.write_file_err__errcode:_d__filename:_s_r_n
jmp 0x4cf53b
mov eax, dword [esp + 0x10]
cmp esi, eax
je 0x4cf492
call fcn.004df100
push 0xf6
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
lea eax, [edi + 4]
add esp, 0xc
cmp dword [eax + 0x14], 8
jb 0x4cf47b
mov eax, dword [eax]
push eax
push dword [esp + 0x14]
push esi
push str.write_file__p_nSize___dwWritten__size:_d__written:_d__filename:_s_r_n
call fcn.004df180
mov eax, dword [esp + 0x20]
add esp, 0x10
mov dword [ebx], eax
mov al, 1
mov dword [edi], 0
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x48]
xor ecx, esp
call fcn.004a35cb
mov esp, ebp
pop ebp
ret 0xc
lea eax, [esp + 0x20]
mov dword [edi], 0x556ba8
push eax
call fcn.004b35c1
lea eax, [esp + 0x24]
push eax
lea eax, [esp + 0x38]
push eax
call fcn.004b4336
push dword [esp + 0x3c]
cmp dword [0x57e638], 8
mov ecx, 0x57e624
push dword [esp + 0x44]
cmovae ecx, dword [0x57e624]
push dword [esp + 0x4c]
mov eax, dword [esp + 0x58]
push dword [esp + 0x54]
inc eax
push eax
mov eax, dword [esp + 0x64]
add eax, 0x76c
push eax
push ecx
push 0x5835b8
push str.__s___s___04d__02d__02d__02d:_02d:_02d_
call fcn.004df180
push 0xd2
push str.t_saFile::Write
push str.__S_L:_d__
call fcn.004df180
add edi, 4
add esp, 0x3c
cmp dword [edi + 0x14], 8
jb 0x4cf534
mov edi, dword [edi]
push edi
push esi
push str.buf_is_null_or_size__d__is_err__filename:_s_r_n
call fcn.004df180
add esp, 0xc
mov ecx, dword [esp + 0x54]
xor al, al
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004a35cb
mov esp, ebp
pop ebp
ret 0xc