Function at 0x22dbe9c40
Capabilities:
Read file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov r12d, dword [rcx + 0x35c]
mov rbx, rcx
test r12d, r12d
jne 0x22dbe9e20
mov r13, qword [rcx + 0x28]
test r13, r13
je 0x22dbe9ee0
sub r13d, dword [rcx + 0x30]
mov ecx, dword [rbx + 0x40]
mov eax, dword [rbx + 0x48]
lea edx, [rcx - 0x10000]
cmp eax, edx
cmovae rdx, rax
cmp ecx, 0xffff
cmova rax, rdx
cmp byte [rbx + 0x44], 0
jne 0x22dbe9cc6
mov dword [rbx + 0x80], 0
cmp qword [rbx + 0x28], 0
je 0x22dbe9f40
mov rdx, qword [rbx + 0x38]
add rax, qword [rbx + 0x30]
cmp rax, rdx
jb 0x22dbe9ef8
mov qword [rbx + 0x28], rdx
mov dword [rbx + 0x80], 1
lea rbp, [rsp + 0x24]
lea rdi, [rsp + 0x20]
mov rcx, rbx
mov r8, rbp
mov rdx, rdi
call fcn.22dbb6bb0
test eax, eax
jne 0x22dbe9d10
jmp 0x22dbe9eb8
mov qword [rbx + 0x28], rdx
mov dword [rbx + 0x80], 1
mov r8, rbp
mov rdx, rdi
mov rcx, rbx
call fcn.22dbb6bb0
test eax, eax
je 0x22dbe9d68
xor esi, esi
cmp byte [rbx + 0x44], 0
jne 0x22dbe9d28
mov rsi, qword [rbx + 0x28]
test rsi, rsi
je 0x22dbe9e40
sub esi, dword [rbx + 0x30]
mov eax, dword [rsp + 0x24]
test eax, eax
jne 0x22dbe9d68
cmp byte [rbx + 0x44], 0
mov eax, dword [rsp + 0x20]
jne 0x22dbe9cfe
mov dword [rbx + 0x80], 0
cmp qword [rbx + 0x28], 0
je 0x22dbe9e58
mov rdx, qword [rbx + 0x38]
add rax, qword [rbx + 0x30]
cmp rax, rdx
jae 0x22dbe9cf0
mov qword [rbx + 0x28], rax
jmp 0x22dbe9cfe
mov edx, esi
mov rcx, rbx
call fcn.22dce7b90
mov rax, qword [rbx + 0x28]
test rax, rax
je 0x22dbea008
lea rdx, [rax + 6]
cmp rdx, qword [rbx + 0x38]
jbe 0x22dbe9f20
mov dword [rbx + 0x80], 1
mov rcx, rbx
call fcn.22dbb1810
mov rcx, rbx
mov edi, eax
call fcn.22dbb1810
mov edx, edi
and edx, eax
cmp edx, 0xffffffff
je 0x22dbe9eb8
test eax, eax
movd xmm1, dword [rsp + 0x20]
mov eax, 0xfffffffe
movd xmm0, esi
cmovne edi, eax
cmp byte [rbx + 0x44], 0
punpckldq xmm0, xmm1
mov dword [rbx + 0x35c], edi
mov r12d, edi
mov dword [rbx + 0x60], edi
movq qword [rbx + 0x58], xmm0
jne 0x22dbe9e20
mov dword [rbx + 0x80], 0
cmp qword [rbx + 0x28], 0
je 0x22dbe9f90
mov rax, qword [rbx + 0x38]
add r13, qword [rbx + 0x30]
cmp r13, rax
jb 0x22dbe9f08
mov qword [rbx + 0x28], rax
mov r12d, dword [rbx + 0x35c]
mov dword [rbx + 0x80], 1
xor eax, eax
cmp r12d, 0xffffffff
cmove r12d, eax
mov eax, r12d
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
mov rcx, qword [rbx + 0x18]
call sub.msvcrt.dll_ftell
sub eax, dword [rbx + 0x20]
mov esi, eax
jmp 0x22dbe9d28
mov edx, eax
add edx, dword [rbx + 0x20]
jb 0x22dbe9ea0
test eax, eax
js 0x22dbe9ea0
mov rcx, qword [rbx + 0x18]
xor r8d, r8d
call sub.msvcrt.dll_fseek
test eax, eax
je 0x22dbe9cfe
mov edx, dword [rbx + 0x20]
mov rcx, qword [rbx + 0x18]
mov r8d, 2
mov dword [rbx + 0x80], 1
call sub.msvcrt.dll_fseek
jmp 0x22dbe9cfe
mov dword [rbx + 0x80], 1
mov edx, 0x7fffffff
jmp 0x22dbe9e63
mov dword [rbx + 0x84], 0x24
cmp byte [rbx + 0x44], 0
mov dword [rbx + 0x35c], 0xffffffff
je 0x22dbe9de5
jmp 0x22dbe9e2a
mov rcx, qword [rcx + 0x18]
call sub.msvcrt.dll_ftell
sub eax, dword [rbx + 0x20]
mov r13d, eax
jmp 0x22dbe9c70
mov qword [rbx + 0x28], rax
jmp 0x22dbe9cc6
mov qword [rbx + 0x28], r13
mov r12d, dword [rbx + 0x35c]
jmp 0x22dbe9e20
mov ecx, dword [rax]
mov dword [rsp + 0x2a], ecx
movzx eax, word [rax + 4]
mov qword [rbx + 0x28], rdx
mov word [rsp + 0x2e], ax
jmp 0x22dbe9d97
mov edx, eax
add edx, dword [rbx + 0x20]
jb 0x22dbe9fd8
test eax, eax
js 0x22dbe9fd8
mov rcx, qword [rbx + 0x18]
xor r8d, r8d
call sub.msvcrt.dll_fseek
test eax, eax
je 0x22dbe9cc6
mov edx, dword [rbx + 0x20]
mov rcx, qword [rbx + 0x18]
mov r8d, 2
mov dword [rbx + 0x80], 1
call sub.msvcrt.dll_fseek
jmp 0x22dbe9cc6
mov edx, r13d
add edx, dword [rbx + 0x20]
jb 0x22dbe9ff0
test r13d, r13d
js 0x22dbe9ff0
mov rcx, qword [rbx + 0x18]
xor r8d, r8d
call sub.msvcrt.dll_fseek
test eax, eax
je 0x22dbe9fc9
mov edx, dword [rbx + 0x20]
mov rcx, qword [rbx + 0x18]
mov r8d, 2
mov dword [rbx + 0x80], 1
call sub.msvcrt.dll_fseek
mov r12d, dword [rbx + 0x35c]
jmp 0x22dbe9e20
mov dword [rbx + 0x80], 1
mov edx, 0x7fffffff
jmp 0x22dbe9f53
mov dword [rbx + 0x80], 1
mov edx, 0x7fffffff
jmp 0x22dbe9f9d
mov r9, qword [rbx + 0x18]
lea rcx, [rsp + 0x2a]
mov r8d, 1
mov edx, 6
call sub.msvcrt.dll_fread
cmp rax, 1
jne 0x22dbe9d8d
jmp 0x22dbe9d97