Function at 0x41fcc0
Capabilities:
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
mov ebx, dword [ebp + 8]
push esi
xor esi, esi
xorps xmm0, xmm0
push edi
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x48], esi
mov dword [ebp - 0x44], esi
movq qword [ebp - 0x40], xmm0
movq qword [ebp - 0x38], xmm0
mov dword [ebp - 0x30], esi
movq qword [ebp - 0x2c], xmm0
mov dword [ebp - 0x24], esi
cmp dword [ebx + 0x10], esi
jne 0x41fd0d
push str.In_valid_argument_to_write_data__empty_document_data.
push 4
call fcn.00417ea0
add esp, 8
mov esi, 0x307
jmp 0x41ff68
mov edi, dword [ebp + 0xc]
cmp dword [edi + 0x14], 0x10
jb 0x41fd1a
mov eax, dword [edi]
jmp 0x41fd1c
mov eax, edi
push eax
call fcn.00404340
add esp, 4
mov dword [ebp + 0xc], eax
cmp eax, esi
jne 0x41fd3a
mov eax, 9
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebp + 0x10], esi
jne 0x41fd58
push str.In_valid_argument_to_write_data__null_document.
push 4
call fcn.00417ea0
add esp, 8
mov esi, 0x307
jmp 0x41ff68
cmp dword [edi + 0x14], 0x10
jb 0x41fd60
mov edi, dword [edi]
push edi
push dword [ebx + 0x10]
push str.Writing_CacheDoc_Data_At_Path___d____s_.
push 4
call fcn.00417ea0
mov eax, dword [ebp + 0x10]
add esp, 0x10
cmp dword [eax + 0x30], esi
lea edi, [eax + 0x30]
je 0x41fd88
cmp dword [eax + 0x34], 0xffffffff
jne 0x41fea2
xorps xmm0, xmm0
movq qword [ebp - 0x18], xmm0
lea ecx, [ebp - 0x48]
movq qword [ebp - 0x20], xmm0
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x18], esi
call fcn.0041ed60
mov esi, eax
test esi, esi
je 0x41fdbd
push str.Failed_to_initialize_SLC_SD_ATTR.
push 4
call fcn.00417ea0
add esp, 8
jmp 0x41ff68
push 0
push str.__slc_features__
push dword [ebp + 0x10]
call fcn.004188f0
add esp, 8
test al, al
mov edx, 0x80
mov ecx, 2
cmovne ecx, edx
push ecx
push 4
lea eax, [ebp - 0x2c]
push eax
push 7
push 0xc0000000
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp + 8], eax
cmp eax, 0xffffffff
jne 0x41fe1d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_open_file_in_write_mode__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x302
jmp 0x41ff68
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 8], eax
cmp eax, 0xffffffff
jne 0x41fe4e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_get_the_file_handle_in_write_mode__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x302
jmp 0x41ff68
test eax, eax
je 0x41fe94
lea ecx, [ebp - 0x20]
push ecx
push 0
push eax
push 0
push 2
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LockFileEx]
cmp eax, 1
je 0x41fe94
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_get_the_file_size_in_write_mode__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x302
jmp 0x41ff68
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 8]
mov dword [edi], eax
mov eax, dword [ebp + 0x10]
mov dword [eax + 0x34], ecx
push 0
push 0
push 0
push dword [edi]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
test eax, eax
je 0x41fed4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_SetFilePointer__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x303
jmp 0x41ff68
cmp dword [ebx + 0x14], 0x10
mov eax, dword [ebx + 0x10]
jb 0x41fedf
mov ebx, dword [ebx]
push 0
lea ecx, [ebp - 0xc]
push ecx
push eax
push ebx
push dword [edi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp eax, 1
je 0x41ff11
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_write_data__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x303
jmp 0x41ff68
push dword [edi]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp eax, 1
je 0x41ff3b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_set_the_eof_marker__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
mov esi, 0x303
jmp 0x41ff68
push dword [edi]
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
test eax, eax
jne 0x41ff5d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_set_FlushFileBuffers__error_code:_d.
push 4
call fcn.00417ea0
add esp, 0xc
test edi, edi
je 0x41ff68
mov ecx, edi
call fcn.0041ffb0
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x41ff78
push eax
call fcn.004dbc6f
add esp, 4
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x41ff8d
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x48], 0
mov eax, dword [ebp - 0x44]
test eax, eax
je 0x41ff9b
push eax
call dword [sym.imp.ADVAPI32.dll_FreeSid]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc