Function at 0x140050090
Capabilities:
Get common file path

Disassembly:
push rsi
push rdi
push rbx
sub rsp, 0x250
mov rax, qword [0x140155cc0]
xor rax, rsp
mov qword [rsp + 0x248], rax
mov sil, 1
cmp qword [0x140164948], 0
jne 0x14005040c
mov rdi, qword [0x140164950]
test rdi, rdi
je 0x1400500db
test byte [0x140155630], 1
jne 0x1400502c7
jmp 0x14005040c
mov ecx, 0x18
call fcn.1400dff64
mov rdi, rax
lea rbx, [rsp + 0x40]
mov r8d, 0x208
mov rcx, rbx
mov dl, 0xaa
call fcn.140114c60
xor ecx, ecx
mov rdx, rbx
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
movaps xmm0, xmmword [section..rdata]
movups xmmword [rdi], xmm0
movabs rax, 0xaaaaaaaaaaaaaaaa
mov qword [rdi + 0x10], rax
mov rcx, rdi
mov rdx, rbx
call fcn.140001850
movsx rax, byte [rdi + 0x17]
mov r8, rax
mov rdx, rdi
test rax, rax
js 0x140050148
test r8, r8
jne 0x140050154
jmp 0x1400501b3
mov rdx, qword [rdi]
mov r8, qword [rdi + 8]
test r8, r8
je 0x1400501b3
add r8, r8
nop word [rax + rax]
test r8, r8
je 0x1400501b3
lea rcx, [r8 - 2]
cmp word [rdx + r8 - 2], 0x5c
mov r8, rcx
jne 0x140050160
cmp rcx, 0xfffffffffffffffe
je 0x1400501b3
sar rcx, 1
lea rdx, [rcx + 1]
test al, al
js 0x140050197
cmp rcx, rax
jae 0x14005048d
mov byte [rdi + 0x17], dl
mov rax, rdi
jmp 0x1400501a8
cmp rcx, qword [rdi + 8]
jae 0x14005048d
mov rax, qword [rdi]
mov qword [rdi + 8], rdx
mov word [rax + rcx*2 + 2], 0
movzx eax, byte [rdi + 0x17]
test al, al
js 0x1400501cf
movzx r9d, al
lea rcx, [r9 - 2]
mov edx, 0xa
mov rax, rdi
cmp rcx, 9
jb 0x1400501f0
jmp 0x140050241
movabs rdx, 0x7fffffffffffffff
and rdx, qword [rdi + 0x10]
dec rdx
mov r9, qword [rdi + 8]
mov rax, rdx
sub rax, r9
cmp rax, 9
jae 0x14005023e
mov r8, r9
sub r8, rdx
add r8, 9
lea rax, str.debug.log
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x30], 9
mov qword [rsp + 0x28], 0
mov rcx, rdi
call fcn.140043610
mov qword [0x140164950], rdi
test byte [0x140155630], 1
jne 0x1400502c7
jmp 0x14005040c
mov rax, qword [rdi]
lea rcx, [rax + r9*2]
lea rdx, [rax + r9*2]
add rdx, 0x12
lea r8, str.debug.log
cmp rcx, r8
seta r10b
cmp rdx, r8
setbe dl
or dl, r10b
je 0x140050467
movups xmm0, xmmword [str.debug.log]
movups xmmword [rcx], xmm0
mov word [rcx + 0x10], 0x67
lea rcx, [r9 + 9]
cmp byte [rdi + 0x17], 0
js 0x1400502a7
and cl, 0x7f
mov byte [rdi + 0x17], cl
mov word [rax + r9*2 + 0x12], 0
mov qword [0x140164950], rdi
test byte [0x140155630], 1
jne 0x1400502c7
jmp 0x14005040c
mov qword [rdi + 8], rcx
mov word [rax + r9*2 + 0x12], 0
mov qword [0x140164950], rdi
test byte [0x140155630], 1
je 0x14005040c
cmp byte [rdi + 0x17], 0
jns 0x1400502d0
mov rdi, qword [rdi]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
mov rcx, rdi
mov edx, 4
mov r8d, 3
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [0x140164948], rax
inc rax
cmp rax, 1
ja 0x14005040c
lea rsi, [rsp + 0x40]
mov r8d, 0x208
mov rcx, rsi
mov dl, 0xaa
call fcn.140114c60
mov word [rsp + 0x40], 0
mov ecx, 0x104
mov rdx, rsi
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
add eax, 0xfffffefb
cmp eax, 0xfffffefc
jb 0x14005040a
mov rcx, qword [0x140164950]
lea rdx, [rsp + 0x40]
call fcn.140043bc0
mov rcx, qword [0x140164950]
movsx rax, byte [rcx + 0x17]
test rax, rax
js 0x14005042d
test al, al
je 0x14005047a
mov rdx, rcx
cmp word [rdx + rax*2 - 2], 0x5c
je 0x1400503a0
lea rdx, [0x14011a81a]
mov r8d, 1
call fcn.140043bf0
mov rcx, qword [0x140164950]
lea rdx, str.debug.log
mov r8d, 9
call fcn.140043bf0
mov rcx, qword [0x140164950]
cmp byte [rcx + 0x17], 0
jns 0x1400503c2
mov rcx, qword [rcx]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
mov edx, 4
mov r8d, 3
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [0x140164948], rax
inc rax
cmp rax, 1
ja 0x14005044a
mov qword [0x140164948], 0
xor esi, esi
mov rcx, qword [rsp + 0x248]
xor rcx, rsp
cmp rcx, qword [0x140155cc0]
jne 0x140050461
mov eax, esi
add rsp, 0x250
pop rbx
pop rdi
pop rsi
ret
mov rax, qword [rcx + 8]
test rax, rax
je 0x14005047a
mov rdx, qword [rcx]
cmp word [rdx + rax*2 - 2], 0x5c
jne 0x140050387
jmp 0x1400503a0
mov sil, 1
mov rcx, qword [rsp + 0x248]
xor rcx, rsp
cmp rcx, qword [0x140155cc0]
je 0x140050420
call fcn.1400e0180
int3
lea rcx, [0x140117223]
lea rdx, str....._third_partylibc_srcinclude__stringchar_traits.h:208:_assertion__std::__is_pointer_in_range___dest____dest____n____src__failed:_char_traits::copy:_source_and_destination_ranges_overlap_n
call fcn.140044b40
lea rcx, [0x140117223]
lea rdx, str....._third_partylibc_srcinclude_string:1449:_assertion__empty___failed:_string::back__:_string_is_empty_n
call fcn.140044b40
mov rcx, rdi
call fcn.140003cc0
int3