Function at 0x463578
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
xor ecx, ecx
push esi
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], ecx
push edi
test esi, esi
jne 0x4635c8
mov ebx, 0x80070057
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push ebx
push 0x269
push edi
mov esi, ebx
call fcn.00401225
push str.Invalid_argument_pcbDest
push ebx
push 0x13
push 5
push 0x269
push edi
call fcn.00401228
add esp, 0x18
jmp 0x4639f3
mov edi, dword [ebp + 8]
test edi, edi
jne 0x4635f8
mov ebx, 0x80070057
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push ebx
push 0x26a
push edi
mov esi, ebx
call fcn.00401225
push str.Invalid_argument_ppbDest
push ebx
push 0x13
push 5
push 0x26a
jmp 0x4635ba
mov ebx, dword [ebp + 0x10]
test ebx, ebx
jne 0x463628
mov ebx, 0x80070057
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push ebx
push 0x26b
push edi
mov esi, ebx
call fcn.00401225
push str.Invalid_argument_wzSrcPath
push ebx
push 0x13
push 5
push 0x26b
jmp 0x4635ba
xor eax, eax
cmp ax, word [ebx]
jne 0x46365b
mov ebx, 0x80070057
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push ebx
push 0x26c
push edi
mov esi, ebx
call fcn.00401225
push str.wzSrcPath_is_null
push ebx
push 0x13
push 5
push 0x26c
jmp 0x4635ba
push ecx
push 0x8000080
push 3
push ecx
push dword [ebp + 0x24]
push SysReAllocString
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x14], eax
cmp eax, 0xffffffff
jne 0x4636f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, 3
je 0x4636da
cmp esi, 2
je 0x4636da
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4636a4
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4636ab
mov esi, 0x80004005
push esi
push 0x276
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push edi
call fcn.00401225
push ebx
push str.Failed_to_open_file:__ls
push esi
push 0x13
push 5
push 0x276
push edi
call fcn.00401228
add esp, 0x1c
jmp 0x4639f3
test esi, esi
jle 0x4639f3
movzx esi, si
or esi, 0x80070000
jmp 0x4639f3
lea ecx, [ebp - 0x20]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x46374c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x463716
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x46371d
mov esi, 0x80004005
push esi
push 0x27b
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push edi
call fcn.00401225
push ebx
push str.Failed_to_get_size_of_file:__ls
push esi
push 0x13
push 5
push 0x27b
push edi
call fcn.00401228
add esp, 0x1c
jmp 0x4639ea
cmp dword [ebp + 0x14], 0
je 0x4637e9
mov eax, dword [ebp + 0x18]
xor ecx, ecx
cmp ecx, dword [ebp - 0x1c]
jl 0x463799
jg 0x463767
cmp eax, dword [ebp - 0x20]
jbe 0x463799
push dword [ebp - 0x1c]
mov ebx, 0x80070057
push dword [ebp - 0x20]
mov esi, ebx
push dword [ebp + 0x10]
push eax
push str.Start_position__d_bigger_than_file__ls_size__llu
push ebx
push 0x13
push 5
push 0x283
push str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
call fcn.00401228
add esp, 0x28
jmp 0x4639ea
push 1
push ecx
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x4637f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4637c2
movzx esi, si
or esi, 0x80070000
test esi, esi
jns 0x4637ed
push esi
mov ebx, 0x289
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push ebx
push edi
call fcn.00401225
push dword [ebp + 0x18]
push str.Failed_to_seek_position__d
push esi
push 0x13
push 5
push ebx
jmp 0x46373e
xor eax, eax
jmp 0x4637f3
mov esi, dword [ebp + 0xc]
mov eax, dword [ebp + 0x18]
cmp dword [ebp + 0x20], 0
je 0x463820
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x10], ecx
cmp dword [edi], 0
je 0x4638a9
test ecx, ecx
jne 0x463869
push dword [edi]
call fcn.004055c9
xor eax, eax
mov dword [edi], eax
mov dword [esi], eax
mov esi, eax
jmp 0x4639ea
mov edx, dword [ebp - 0x20]
mov ecx, edx
sub ecx, eax
sub edx, eax
mov eax, dword [ebp - 0x1c]
sbb eax, 0
mov dword [ebp - 0x10], ecx
cmp dword [ebp - 0x18], eax
jg 0x4637ff
jl 0x46383e
cmp dword [ebp + 0x1c], edx
jae 0x4637ff
mov esi, 0x8007007a
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push esi
push 0x29b
push edi
call fcn.00401225
push ebx
push str.Failed_to_load_file:__ls__too_large.
push esi
push 0x13
push 5
push 0x29b
jmp 0x46373e
push 1
push ecx
push dword [edi]
call fcn.004056c2
mov edi, eax
mov dword [ebp - 4], edi
test edi, edi
jne 0x4638f2
mov eax, 0x8007000e
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push eax
push 0x2a9
push edi
mov esi, eax
call fcn.00401225
push ebx
push str.Failed_to_re_allocate_memory_to_read_in_file:__ls
push esi
push 0x13
push 5
push 0x2a9
jmp 0x46373e
test ecx, ecx
jne 0x4638b4
xor eax, eax
jmp 0x463817
push 1
push ecx
call fcn.0040540b
mov edi, eax
mov dword [ebp - 4], eax
test edi, edi
jne 0x4638f2
mov eax, 0x8007000e
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push eax
push 0x2b6
push edi
mov esi, eax
call fcn.00401225
push ebx
push str.Failed_to_allocate_memory_to_read_in_file:__ls
push esi
push 0x13
push 5
push 0x2b6
jmp 0x46373e
xor ecx, ecx
mov eax, ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], eax
jmp 0x463900
xor ecx, ecx
mov dword [ebp - 0x18], ecx
lea ecx, [ebp - 0x18]
push ecx
push eax
push dword [ebp - 0x10]
call fcn.00459b37
mov esi, eax
test esi, esi
js 0x4639c1
mov ecx, dword [ebp - 8]
xor eax, eax
push eax
lea eax, [ebp - 0xc]
add ecx, edi
push eax
push dword [ebp - 0x18]
push ecx
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x46397f
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0xc]
cmp dword [ebp - 0xc], 0
mov dword [ebp - 8], eax
jne 0x4638fe
mov ecx, dword [ebp - 0x10]
cmp eax, ecx
je 0x463971
push ebx
push str.Failed_to_completely_read_file:__ls
mov esi, 0x8000ffff
push esi
push 0x13
push 5
push 0x2cc
push str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
call fcn.00401228
add esp, 0x1c
jmp 0x4639dd
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
mov dword [eax], edi
xor eax, eax
mov dword [edx], ecx
jmp 0x4639e0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x463996
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x46399d
mov esi, 0x80004005
push esi
push 0x2c3
mov edi, str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
push edi
call fcn.00401225
push ebx
push str.Failed_to_read_from_file:__ls
push esi
push 0x13
push 5
push 0x2c3
push edi
jmp 0x463967
push str.Underflow_calculating_remaining_buffer_size.
push esi
push 0x13
push 5
push 0x2bf
push str.d:_awixwix_srclibsdutilwixtoolset.dutil_fileutil.cpp
call fcn.00401228
add esp, 0x18
mov eax, dword [ebp - 4]
test eax, eax
je 0x4639ea
push eax
call fcn.004055c9
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0x20