Function at 0x10004e608
Capabilities:
Get common file path
Set current directory

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
sub rsp, 0x6c0
mov rax, qword [0x100190170]
xor rax, rsp
mov qword [rsp + 0x6b0], rax
call fcn.10004e4d8
mov cl, byte [0x10019018a]
xor esi, esi
mov rbx, rax
lea rbp, [0x10019a4f8]
cmp cl, sil
je 0x10004e661
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov cl, byte [0x10019018a]
mov byte [rbx + 0x22f], 1
cmp cl, sil
je 0x10004e676
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
or dword [rsp + 0x30], 0xffffffff
lea rcx, [rsp + 0x30]
mov r12d, 8
mov dword [rsp + 0x34], r12d
call qword [sym.imp.COMCTL32.dll_InitCommonControlsEx]
lea r8, [rsp + 0x28]
lea ecx, [r12 + 0x32]
xor r9d, r9d
mov edx, r12d
mov dword [rsp + 0x28], r12d
mov dword [rsp + 0x2c], esi
call qword [sym.imp.USER32.dll_SystemParametersInfoW]
mov rbx, qword [rsp + 0x28]
call fcn.10004e4d8
mov cl, byte [0x10019018a]
mov rdi, rax
cmp cl, sil
je 0x10004e6d7
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov cl, byte [0x10019018a]
mov qword [rdi + 0x1f4], rbx
cmp cl, sil
je 0x10004e6ec
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor r9d, r9d
lea r8, [rsp + 0x20]
mov edx, r12d
lea ecx, [r9 + 0x34]
mov dword [rsp + 0x20], r12d
mov dword [rsp + 0x24], esi
call qword [sym.imp.USER32.dll_SystemParametersInfoW]
mov rbx, qword [rsp + 0x20]
call fcn.10004e4d8
mov cl, byte [0x10019018a]
mov rdi, rax
cmp cl, sil
je 0x10004e731
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov cl, byte [0x10019018a]
mov qword [rdi + 0x1fc], rbx
cmp cl, sil
je 0x10004e746
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
mov r12d, 0x18
lea r8, [rsp + 0x38]
lea ecx, [rax + 0x32]
xor r9d, r9d
mov edx, r12d
mov dword [rsp + 0x38], r12d
mov dword [rsp + 0x3c], esi
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], rax
call qword [sym.imp.USER32.dll_SystemParametersInfoW]
lea rcx, [rsp + 0x38]
mov rax, qword [rcx]
lea r11, [rsp + 0x60]
mov qword [r11], rax
mov rax, qword [rcx + 8]
mov qword [r11 + 8], rax
mov rax, qword [rcx + 0x10]
mov qword [r11 + 0x10], rax
call fcn.10004e4d8
mov bl, byte [0x10019018a]
mov rdi, rax
cmp bl, sil
je 0x10004e7b7
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov bl, byte [0x10019018a]
lea rcx, [rdi + 0x204]
lea rdx, [rsp + 0x60]
mov r8, r12
call sub.msvcrt.dll_memcpy
cmp bl, sil
je 0x10004e7d9
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ebx, 0x206
lea rcx, [rsp + 0x82]
xor edx, edx
mov r8, rbx
mov word [rsp + 0x80], si
call sub.msvcrt.dll_memset
lea rcx, [rsp + 0x4a2]
mov r8, rbx
xor edx, edx
mov word [rsp + 0x4a0], si
call sub.msvcrt.dll_memset
mov r12d, 0x104
lea rdx, [rsp + 0x80]
mov r8d, r12d
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea rcx, [rsp + 0x80]
mov edx, 0x5c
mov word [rsp + 0x286], si
call qword [sym.imp.msvcrt.dll_wcsrchr]
mov rbx, rax
cmp rax, rsi
je 0x10004e880
lea r8, [rax + 2]
lea rcx, [rsp + 0x4a0]
mov rdx, r12
call sub.msvcrt.dll_wcscpy_s
lea rcx, [rsp + 0x4a0]
mov edx, 0x2e
mov word [rbx], si
call qword [sym.imp.msvcrt.dll_wcsrchr]
cmp rax, rsi
je 0x10004e880
mov word [rax], si
lea rcx, [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
call fcn.10004e4d8
mov cl, byte [0x10019018a]
mov rbx, rax
cmp cl, sil
je 0x10004e8b0
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov cl, byte [0x10019018a]
mov byte [rbx + 0x21c], 1
cmp cl, sil
je 0x10004e8c5
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call fcn.10004eaa0
call fcn.100056830
mov rbx, rax
cmp rax, rsi
jne 0x10004e947
call fcn.100060234
cmp al, sil
je 0x10004e8f9
mov rax, qword [0x10019f5c0]
cmp rax, rsi
je 0x10004e8f9
mov ecx, 0x20
call rax
mov rbx, rax
jmp 0x10004e8fc
mov rbx, rsi
call fcn.10004e4d8
mov cl, byte [0x10019018a]
mov rdi, rax
cmp cl, sil
je 0x10004e91e
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov cl, byte [0x10019018a]
mov qword [rdi], rbx
cmp cl, sil
je 0x10004e92f
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp rbx, rsi
jne 0x10004e947
mov ebx, 0x80040901
mov ecx, ebx
call fcn.100056e98
mov eax, ebx
jmp 0x10004ea6a
lea rcx, [rsp + 0x290]
mov edx, 0x105
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
jne 0x10004e968
mov eax, 0x80004005
jmp 0x10004ea6a
lea r8, [0x100027c18]
lea rcx, [rsp + 0x290]
mov rdx, r12
mov word [rsp + 0x498], si
call sub.msvcrt.dll_wcscat_s
lea rcx, [rsp + 0x290]
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov qword [0x1001a7300], rax
cmp rax, rsi
je 0x10004e9e7
lea rdx, [0x100027c38]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp rax, rsi
je 0x10004e9d9
mov r8, qword [rbx]
mov rdx, rax
mov rcx, rbx
call qword [r8 + 0x18]
cmp eax, esi
jl 0x10004e9d0
lea rcx, [0x100027c50]
jmp 0x10004e9e0
lea rcx, [0x100027ca0]
jmp 0x10004e9e0
lea rcx, [0x100027cf0]
call fcn.10006021c
jmp 0x10004e9fb
lea rdx, [rsp + 0x290]
lea rcx, [0x100027d70]
call fcn.10006021c
call fcn.10005fcc4
mov rbx, rax
cmp byte [rax], sil
je 0x10004ea31
mov rcx, qword [rax + 0x10]
cmp rcx, rsi
jne 0x10004ea21
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov rcx, qword [rsp + 0x50]
mov qword [rbx + 0x20], rcx
mov qword [rbx + 0x18], rcx
mov qword [rbx + 0x10], rsi
mov byte [rbx + 1], sil
call fcn.10004e4d8
mov dl, byte [0x10019018a]
mov rbx, rax
cmp dl, sil
je 0x10004ea53
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dl, byte [0x10019018a]
mov byte [rbx + 0x22c], 1
cmp dl, sil
je 0x10004ea68
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
mov rcx, qword [rsp + 0x6b0]
xor rcx, rsp
call fcn.10017a260
lea r11, [rsp + 0x6c0]
mov rbx, qword [r11 + 0x10]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r12
ret