Function at 0x14004f360
Capabilities:
Write file on windows

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0xa8
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x20], 0xfffffffffffffffe
mov r13, rcx
cmp byte [0x1401aea98], 0
jne 0x14004f3db
call fcn.140077f4b
test al, al
jne 0x14004f3db
lea rsi, str.WARNING:_Logging_before_InitGoogleLogging___is_written_to_STDERR_n
lea rbx, [rbp - 0x40]
mov ecx, 8
mov rdi, rbx
rep movsq qword [rdi], qword [rsi]
mov word [rbx + 0x40], 0xa
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov edx, 0x41
mov r8d, 1
mov rcx, rbx
mov r9, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
mov byte [0x1401aea98], 1
mov al, byte [0x14019f77d]
mov cl, byte [0x14019f779]
or cl, al
mov qword [rbp + 0x10], r13
jne 0x14004f440
call fcn.140077f4b
test al, al
je 0x14004f43a
cmp byte [0x14019f77d], 0
jne 0x14004f59f
mov rax, qword [r13 + 8]
mov r12, qword [rax + 0x7670]
lea r15, [rax + 4]
mov dl, byte [rax + 0x7620]
movsx ecx, dl
cmp byte [0x14019f779], 0
je 0x14004f528
mov rdx, r15
mov r8, r12
call fcn.14004fd24
jmp 0x14004f59f
mov al, byte [0x14019f77d]
test al, al
jne 0x14004f45f
mov rdx, qword [r13 + 8]
mov r8, qword [rdx + 0x7670]
movsx ecx, byte [rdx + 0x7620]
add rdx, 4
call fcn.14004fd24
mov rsi, qword [r13 + 8]
mov r15, qword [rsi + 0x7668]
mov rdi, r15
not rdi
mov eax, dword [rsi + 0x7624]
mov dword [rbp + 0x18], eax
mov r14, qword [rsi + 0x7680]
mov r12, qword [rsi + 0x7688]
movsx ebx, byte [rsi + 0x7620]
add rdi, qword [rsi + 0x7670]
lea rax, [0x14019faa8]
mov qword [rbp - 0x40], rax
cmp byte [0x14019fad0], 0
je 0x14004f4b6
lea rcx, [0x14019faa8]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x14019faa0]
test rax, rax
je 0x14004f698
add r15, rsi
add r15, 4
add rsi, 0x7640
mov r13, qword [rax + 8]
sub r13, qword [rax]
shr r13, 3
dec r13d
test r13d, r13d
js 0x14004f698
mov rax, qword [0x14019faa0]
mov ecx, r13d
mov rax, qword [rax]
mov rcx, qword [rax + rcx*8]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
dec r13d
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x28], rsi
mov edx, dword [rbp + 0x18]
mov dword [rsp + 0x20], edx
mov edx, ebx
mov r8, r12
mov r9, r14
call rax
jmp 0x14004f4e2
test dl, dl
js 0x14004f59f
mov r14, qword [rax + 0x7638]
mov ebx, ecx
lea rax, [0x14019fae0]
lea rsi, [rax + rbx*8]
movsxd rdi, dword [0x14019f818]
mov rax, qword [rsi]
test rax, rax
jne 0x14004f571
mov ecx, 0xc8
call fcn.1400e7770
mov qword [rbp + 0x18], rax
mov rcx, rax
mov edx, ebx
xor r8d, r8d
call fcn.14004e9cc
mov rax, qword [rbp + 0x18]
mov qword [rsi], rax
cmp rbx, rdi
setg dl
mov rcx, qword [rax + 0xc0]
mov rax, qword [rcx]
mov dword [rsp + 0x20], r12d
mov r8, r14
mov r9, r15
call qword [rax + 8]
lea rax, [rbx - 1]
add rsi, 0xfffffffffffffff8
test rbx, rbx
mov rbx, rax
jg 0x14004f540
mov rdx, qword [r13 + 8]
mov r8, qword [rdx + 0x7670]
movsx ecx, byte [rdx + 0x7620]
add rdx, 4
call fcn.14004fe3a
mov rdx, qword [r13 + 8]
mov r8, qword [rdx + 0x7670]
movsx ecx, byte [rdx + 0x7620]
add rdx, 4
call fcn.14004ff38
mov rsi, qword [r13 + 8]
mov rbx, qword [rsi + 0x7668]
mov rdi, rbx
not rdi
mov eax, dword [rsi + 0x7624]
mov dword [rbp + 0x18], eax
mov r14, qword [rsi + 0x7680]
mov r12, qword [rsi + 0x7688]
movsx r15d, byte [rsi + 0x7620]
add rdi, qword [rsi + 0x7670]
lea rax, [0x14019faa8]
mov qword [rbp - 0x40], rax
cmp byte [0x14019fad0], 0
je 0x14004f62d
lea rcx, [0x14019faa8]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x14019faa0]
test rax, rax
je 0x14004f698
add rbx, rsi
add rbx, 4
add rsi, 0x7640
mov r13, qword [rax + 8]
sub r13, qword [rax]
shr r13, 3
dec r13d
test r13d, r13d
js 0x14004f698
mov rax, qword [0x14019faa0]
mov ecx, r13d
mov rax, qword [rax]
mov rcx, qword [rax + rcx*8]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
dec r13d
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rsi
mov edx, dword [rbp + 0x18]
mov dword [rsp + 0x20], edx
mov edx, r15d
mov r8, r12
mov r9, r14
call rax
jmp 0x14004f655
lea rcx, [rbp - 0x40]
call fcn.14004f94c
mov r14, qword [rbp + 0x10]
mov rax, qword [r14 + 8]
cmp byte [rax + 0x7620], 3
jne 0x14004f6bb
cmp byte [0x140199d84], 0
jne 0x14004f6cf
add rsp, 0xa8
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
cmp byte [rax + 0x7691], 0
je 0x14004f76e
lea rax, [0x14019fc50]
mov rcx, qword [0x1401a72d8]
mov qword [0x14019fb30], rcx
lea rcx, [0x14019fb30]
mov edx, dword [0x1401a7274]
mov dword [0x14019fb38], edx
mov rdx, qword [0x1401a72b8]
add rax, rdx
add rax, 4
mov qword [0x14019fb40], rax
mov dword [0x14019fc48], 0
call fcn.1400781dc
mov rbx, r14
mov rdx, qword [r14 + 8]
mov eax, dword [rdx + 0x7670]
mov ecx, 0xff
cmp eax, ecx
cmovl ecx, eax
add rdx, 4
movsxd rsi, ecx
lea rdi, [0x1401ae990]
mov rcx, rdi
mov r8, rsi
call sub.VCRUNTIME140.dll_memcpy
mov byte [rsi + rdi], 0
mov rax, qword [r14 + 8]
mov rax, qword [rax + 0x7638]
mov qword [0x1401aea90], rax
mov al, byte [0x14019f779]
or al, byte [0x14019f77d]
jne 0x14004f7bc
xor edi, edi
lea rbx, [0x14019fae0]
lea rsi, [0x140147ab9]
mov rax, qword [rdi + rbx]
test rax, rax
je 0x14004f7b2
mov rcx, qword [rax + 0xc0]
mov rax, qword [rcx]
mov dword [rsp + 0x20], 0
mov dl, 1
xor r8d, r8d
mov r9, rsi
call qword [rax + 8]
add rdi, 8
cmp rdi, 0x20
jne 0x14004f78c
lea rcx, [0x14019fa10]
call fcn.140050804
mov rcx, qword [r14 + 8]
call fcn.14004fc54
lea rdx, str._Check_failure_stack_trace:__n
mov ecx, 2
mov r8d, 0x23
call sub.api_ms_win_crt_stdio_l1_1_0.dll__write
call qword [0x140199d88]
int3