Function at 0x140029c80
Capabilities:
Set current directory

Disassembly:
mov rax, rsp
mov qword [rax + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x160
cmp byte [0x140137fc8], 0
mov ebp, r8d
mov esi, edx
mov dword [rcx + 0xb44], edx
mov rdi, rcx
jne 0x140029f47
cmp byte [rcx + 0xbb4], 0
je 0x140029f47
mov rcx, qword [0x140134210]
mov dword [0x140138d60], r8d
xor r8d, r8d
mov qword [rax + 8], rbx
mov qword [rax + 0x10], r15
lea edx, [r8 + 1]
call fcn.1400016b0
mov r8d, 0x7f
lea rcx, [rsp + 0x60]
mov rdx, rax
call fcn.1400de184
mov r8, qword [0x14012fc08]
lea rcx, [0x1401340a0]
inc dword [0x140134218]
xor r15d, r15d
add r8, 0x150
mov word [rsp + 0x15e], r15w
mov qword [0x14012fc08], r8
mov rax, r8
lea edx, [r15 + 2]
lea rax, [rax + 0x80]
movups xmm0, xmmword [rcx]
lea rcx, [rcx + 0x80]
movups xmmword [rax - 0x80], xmm0
movups xmm1, xmmword [rcx - 0x70]
movups xmmword [rax - 0x70], xmm1
movups xmm0, xmmword [rcx - 0x60]
movups xmmword [rax - 0x60], xmm0
movups xmm1, xmmword [rcx - 0x50]
movups xmmword [rax - 0x50], xmm1
movups xmm0, xmmword [rcx - 0x40]
movups xmmword [rax - 0x40], xmm0
movups xmm1, xmmword [rcx - 0x30]
movups xmmword [rax - 0x30], xmm1
movups xmm0, xmmword [rcx - 0x20]
movups xmmword [rax - 0x20], xmm0
movups xmm1, xmmword [rcx - 0x10]
movups xmmword [rax - 0x10], xmm1
sub rdx, 1
jne 0x140029d24
movups xmm0, xmmword [rcx]
movups xmmword [rax], xmm0
movups xmm1, xmmword [rcx + 0x10]
movups xmmword [rax + 0x10], xmm1
movups xmm0, xmmword [rcx + 0x20]
movups xmmword [rax + 0x20], xmm0
movups xmm1, xmmword [rcx + 0x30]
movups xmmword [rax + 0x30], xmm1
movups xmm0, xmmword [rcx + 0x40]
lea rcx, [0x140136640]
movups xmmword [rax + 0x40], xmm0
mov dword [r8 + 0x3c], r15d
call fcn.140029490
cmp dword [0x14013423c], r15d
mov qword [0x140137210], r15
je 0x140029de0
mov rax, qword [0x1401320f0]
lea rcx, [0x1400fb87c]
test rax, rax
je 0x140029dda
mov rax, qword [rax]
test rax, rax
cmovne rcx, rax
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov rcx, qword [0x140132038]
cmp rcx, qword [0x140132040]
mov r14d, dword [0x14012fc00]
mov dword [0x14012fc00], r15d
mov byte [0x140137fc8], 1
jne 0x140029e11
call fcn.140007450
mov rcx, qword [0x140132038]
cmp rcx, qword [0x140132030]
jb 0x140029e2b
mov rax, qword [0x140136ce0]
mov qword [rcx], rax
mov rcx, qword [0x140132038]
add rcx, 0x18
mov byte [0x140132588], r15b
mov qword [0x140132038], rcx
lea rax, str.OnExit
mov bl, 1
mov qword [rcx], r15
mov qword [rcx + 8], rax
mov dword [rcx + 0x10], r15d
mov rcx, qword [rdi + 0xb30]
test rcx, rcx
je 0x140029e74
call fcn.1400017b0
test eax, eax
je 0x140029e74
cmp byte [0x140132588], r15b
movzx ebx, bl
cmove ebx, r15d
mov byte [0x140132588], 1
test bl, bl
je 0x140029ed1
mov dword [rsp + 0x30], r15d
call fcn.14006bf90
mov r9d, r15d
mov qword [rsp + 0x20], rax
cmp qword [rdi + 0xb30], r9
lea rcx, [rdi + 0xae0]
movsxd rax, dword [0x140138d60]
lea rdx, [rsp + 0x20]
sete r9b
mov dword [rsp + 0x50], 1
mov r8d, 2
mov qword [rsp + 0x40], rax
call fcn.1400a6e80
cmp eax, 3
movzx ebx, bl
cmove ebx, r15d
mov rax, qword [0x140132038]
mov r15, qword [rsp + 0x188]
sub rax, 0x18
cmp rax, qword [0x140132030]
mov qword [0x140132038], rax
jb 0x140029f05
mov rax, qword [rax]
mov qword [0x140132058], rax
mov qword [0x140136ce0], rax
test bl, bl
mov byte [0x140137fc8], 0
mov rbx, qword [rsp + 0x180]
jne 0x140029f71
cmp esi, 0xffffffff
jle 0x140029f71
lea rcx, [rsp + 0x60]
call fcn.140005640
mov dword [0x14012fc00], r14d
mov rbp, qword [rsp + 0x190]
mov eax, 8
add rsp, 0x160
pop r14
pop rdi
pop rsi
ret
cmp byte [0x140132588], 0
jne 0x140029f71
cmp esi, 6
jne 0x140029f71
mov rax, qword [0x140136530]
cmp word [rax], 0
je 0x140029f68
mov dword [0x140138d60], ebp
mov byte [0x140132588], 1
jmp 0x140029f2e
mov r8d, ebp
mov edx, esi
mov rcx, rdi
call fcn.140029f80
int3