Function at 0x140006670
Capabilities:
Resume thread
Suspend thread

Disassembly:
push rbp
push rdi
sub rsp, 0x38
cmp byte [0x140105d20], 0
mov ebp, edx
mov rdi, rcx
jne 0x14000668e
xor eax, eax
add rsp, 0x38
pop rdi
pop rbp
ret
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x30], rsi
mov esi, dword gs:[0x48]
cmp dword [0x140105110], esi
je 0x1400066b5
mov rcx, qword [0x140105118]
call qword [sym.imp.KERNEL32.dll_SuspendThread]
cmp word [rdi], 0
jne 0x1400066bf
xor ebx, ebx
jmp 0x140006717
lea rax, [rsp + 0x60]
xor r8d, r8d
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x68]
mov rdx, rdi
mov dword [rsp + 0x20], 3
lea rcx, [0x140105140]
call fcn.1400384b0
mov rbx, rax
test rax, rax
jne 0x140006717
cmp byte [rsp + 0x60], bl
lea rcx, [0x140105140]
mov r9d, dword [rsp + 0x68]
mov rdx, rdi
setne bl
xor r8d, r8d
inc ebx
mov dword [rsp + 0x20], ebx
call fcn.1400389f0
mov rbx, rax
movzx ecx, byte [rbx + 0x23]
test ebp, ebp
je 0x140006781
cmp cl, 4
je 0x1400068ac
mov rcx, qword [0x140101a80]
mov edx, reloc.OLEAUT32.dll_SafeArrayLock
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
test rax, rax
je 0x140006896
cmp dword [0x140105110], esi
mov qword [0x140101a80], rax
je 0x140006766
mov rcx, qword [0x140105118]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rax, qword [0x140101a80]
mov rdx, rax
mov rcx, rbx
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x30]
add rsp, 0x38
pop rdi
pop rbp
jmp fcn.140001430
cmp cl, 4
je 0x1400067a4
test cl, cl
jne 0x140006790
mov rax, qword [rbx + 0x10]
jmp 0x140006793
mov rax, rbx
test byte [rax + 0x21], 0xa
jne 0x1400067a4
cmp qword [rax + 0x10], 0
je 0x1400068ac
mov rax, qword [rbx + 8]
cmp word [rax], 0
jne 0x14000686a
mov rbp, qword [rbx + 0x18]
cmp cl, 4
jne 0x1400067c7
mov rdx, rdi
xor ecx, ecx
call rbp
mov rbp, rax
jmp 0x1400067d0
test rbp, rbp
jne 0x1400067d0
mov rbp, qword [rbx + 0x10]
mov rcx, qword [0x140101a80]
lea rdx, [rbp + 0x101]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
test rax, rax
je 0x140006896
movzx ecx, byte [rbx + 0x23]
mov qword [0x140101a80], rax
cmp cl, 4
jne 0x140006839
mov r8, qword [rbx + 0x18]
lea rcx, [0x1400601f0]
cmp r8, rcx
mov rdx, rdi
mov rcx, rax
jne 0x140006831
add qword [0x1400fe060], 0x150
call r8
sub qword [0x1400fe060], 0x150
jmp 0x140006916
call r8
jmp 0x140006916
test cl, cl
jne 0x140006851
mov rcx, qword [rbx + 0x10]
mov rdx, rax
mov rcx, qword [rcx]
call fcn.140001430
jmp 0x140006916
cmp cl, 1
jne 0x140006916
mov rcx, qword [rbx]
mov rdx, rax
call fcn.140001430
jmp 0x140006916
cmp cl, 4
jne 0x140006879
mov rdx, rdi
xor ecx, ecx
call qword [rbx + reloc.OLEAUT32.dll_SafeArrayGetElement]
jmp 0x140006881
mov rax, qword [rbx + 0x10]
add rax, 2
mov rcx, qword [0x140101a80]
mov rdx, rax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
test rax, rax
jne 0x1400068d9
mov r8, rdi
lea rdx, str.Out_of_memory.
lea rcx, [0x140105140]
call fcn.140046d70
cmp dword [0x140105110], esi
je 0x1400068c1
mov rcx, qword [0x140105118]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rbx, qword [rsp + 0x50]
lea rax, [0x1400cb664]
mov rsi, qword [rsp + 0x30]
add rsp, 0x38
pop rdi
pop rbp
ret
movzx ecx, byte [rbx + 0x23]
mov qword [0x140101a80], rax
test cl, cl
jne 0x1400068f6
mov rcx, qword [rbx + 0x10]
mov rdx, rax
call fcn.1400b0180
jmp 0x140006916
cmp cl, 1
jne 0x140006908
mov rdx, rax
mov rcx, rbx
call fcn.1400b0180
jmp 0x140006916
cmp cl, 4
jne 0x140006916
mov rdx, rdi
mov rcx, rax
call qword [rbx + reloc.OLEAUT32.dll_SafeArrayGetElement]
cmp dword [0x140105110], esi
je 0x14000692b
mov rcx, qword [0x140105118]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rax, qword [0x140101a80]
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x30]
add rsp, 0x38
pop rdi
pop rbp
ret