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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x68
mov eax, dword [ebp + 8]
xorps xmm0, xmm0
push esi
xor esi, esi
movq qword [esp + 0x60], xmm0
push edi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x48], esi
mov dword [esp + 0x4c], esi
movups xmmword [esp + 0x50], xmm0
mov dword [esp + 0x60], esi
mov dword [esp + 0x6c], esi
cmp dword [eax + 0x10], esi
jne 0x472300
push str.In_valid_argument_to_write_data__empty_document_data.
push 4
call fcn.0046cc00
add esp, 8
mov esi, 0x307
jmp 0x472564
mov edi, dword [ebp + 0xc]
cmp dword [edi + 0x14], 0x10
jb 0x47230d
mov eax, dword [edi]
jmp 0x47230f
mov eax, edi
push eax
call fcn.0045af40
add esp, 4
mov dword [esp + 0x14], eax
cmp eax, esi
jne 0x47232d
mov eax, 9
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebp + 0x10], esi
jne 0x47234b
push str.In_valid_argument_to_write_data__null_document.
push 4
call fcn.0046cc00
add esp, 8
mov esi, 0x307
jmp 0x472564
cmp dword [edi + 0x14], 0x10
jb 0x472353
mov edi, dword [edi]
mov eax, dword [ebp + 8]
push edi
push dword [eax + 0x10]
push str.Writing_CacheDoc_Data_At_Path___d____s_.
push 4
call fcn.0046cc00
mov eax, dword [ebp + 0x10]
add esp, 0x10
cmp dword [eax + 0x30], esi
lea edi, [eax + 0x30]
je 0x47237e
cmp dword [eax + 0x34], 0xffffffff
jne 0x47249f
xorps xmm0, xmm0
mov dword [esp + 0x30], esi
movaps xmmword [esp + 0x20], xmm0
lea ecx, [esp + 0x48]
mov dword [esp + 0x28], esi
call fcn.00471350
mov esi, eax
test esi, esi
je 0x4723b1
push str.Failed_to_initialize_SLC_SD_ATTR.
push 4
call fcn.0046cc00
add esp, 8
jmp 0x472564
push 0
push str.__slc_features__
push dword [ebp + 0x10]
call fcn.0046d7f0
add esp, 8
mov edx, 0x80
test al, al
mov ecx, 2
lea eax, [esp + 0x68]
cmovne ecx, edx
push ecx
push 4
push eax
push 7
push 0xc0000000
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esp + 0x10], eax
cmp eax, 0xffffffff
jne 0x472414
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.0046cc00
add esp, 0xc
mov esi, 0x302
jmp 0x472564
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esp + 0x18], eax
cmp eax, 0xffffffff
jne 0x472446
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.0046cc00
add esp, 0xc
mov esi, 0x302
jmp 0x472564
test eax, eax
je 0x47248f
lea ecx, [esp + 0x20]
push ecx
push 0
push eax
push 0
push 2
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_LockFileEx]
cmp eax, 1
je 0x47248f
push dword [esp + 0x10]
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.0046cc00
add esp, 0xc
mov esi, 0x302
jmp 0x472564
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x18]
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 0x4724d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_SetFilePointer__error_code:_d.
push 4
call fcn.0046cc00
add esp, 0xc
mov esi, 0x303
jmp 0x472564
mov eax, dword [ebp + 8]
cmp dword [eax + 0x14], 0x10
mov ecx, dword [eax + 0x10]
jb 0x4724df
mov eax, dword [eax]
push 0
lea edx, [esp + 0x20]
push edx
push ecx
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp eax, 1
je 0x472512
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_write_data__error_code:_d.
push 4
call fcn.0046cc00
add esp, 0xc
mov esi, 0x303
jmp 0x472564
push dword [edi]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp eax, 1
je 0x47253c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_set_the_eof_marker__error_code:_d.
push 4
call fcn.0046cc00
add esp, 0xc
mov esi, 0x303
jmp 0x472564
push dword [edi]
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
test eax, eax
jne 0x47255e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_set_FlushFileBuffers__error_code:_d.
push 4
call fcn.0046cc00
add esp, 0xc
push edi
call fcn.004725b0
mov eax, dword [esp + 0x14]
test eax, eax
je 0x472575
push eax
call fcn.00524165
add esp, 4
mov eax, dword [esp + 0x48]
test eax, eax
je 0x47258c
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [esp + 0x48], 0
mov eax, dword [esp + 0x4c]
test eax, eax
je 0x47259b
push eax
call dword [sym.imp.ADVAPI32.dll_FreeSid]
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 0xc