Function at 0x4e4ed0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x744685
push eax
mov dword fs:[0], esp
sub esp, 0x448
push esi
push edi
mov edi, dword [ebp + 0x10]
cmp edi, 3
jne 0x4e501d
push 0x104
lea eax, [ebp - 0x454]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
xor eax, eax
mov dword [ebp - 0x3c], 0
lea ecx, [ebp - 0x454]
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x28], 7
lea edx, [ecx + 2]
mov word [ebp - 0x3c], ax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4e4f34
sub ecx, edx
lea eax, [ebp - 0x454]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x3c]
call fcn.00486be0
lea ecx, [ebp - 0x3c]
mov dword [ebp - 4], 0
call fcn.005e2b10
mov esi, dword [ebp + 0x14]
test esi, esi
je 0x4e4fbf
cmp byte [esi], 0
je 0x4e4f9a
lea ecx, [ebp - 0x3c]
call fcn.005e2510
mov edi, eax
call fcn.005e11b0
push eax
lea eax, [ebp - 0x3c]
push eax
push 0
push esi
call fcn.005e0910
add esp, 0x10
test edi, edi
je 0x4e4f9a
push edi
lea ecx, [ebp - 0x3c]
call fcn.005e2560
cmp byte [ebp + 0xc], 0
je 0x4e4fbf
mov dword [ebp - 0x44], 0
call fcn.005e0840
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x3c]
push eax
call fcn.00528790
add esp, 8
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x3c]
push eax
mov ecx, esi
call fcn.00492550
mov edx, dword [ebp - 0x28]
cmp edx, 8
jb 0x4e5176
mov ecx, dword [ebp - 0x3c]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4e5001
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4e5188
push edx
push ecx
call fcn.00516d60
add esp, 8
mov eax, esi
pop edi
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
movzx esi, byte [ebp + 0xc]
lea ecx, [ebp - 0x24]
push ebx
push 0
push 0x769f0c
shl esi, 0xf
call fcn.004e4b80
mov ebx, dword [ebp + 0x14]
mov dword [ebp - 4], 1
test ebx, ebx
je 0x4e5077
cmp byte [ebx], 0
je 0x4e5077
lea ecx, [ebp - 0x24]
call fcn.005e2510
mov dword [ebp + 0x10], eax
call fcn.005e11b0
push eax
lea eax, [ebp - 0x24]
push eax
push 0
push ebx
call fcn.005e0910
mov eax, dword [ebp + 0x10]
add esp, 0x10
test eax, eax
je 0x4e5077
push eax
lea ecx, [ebp - 0x24]
call fcn.005e2560
mov eax, edi
pop ebx
sub eax, 0
je 0x4e50ad
sub eax, 1
je 0x4e509b
sub eax, 1
jne 0x4e50d5
cmp dword [ebp - 0x10], 8
lea ecx, [ebp - 0x24]
mov eax, esi
cmovae ecx, dword [ebp - 0x24]
or eax, 0xe
jmp 0x4e50bd
cmp dword [ebp - 0x10], 8
lea ecx, [ebp - 0x24]
mov eax, esi
cmovae ecx, dword [ebp - 0x24]
or eax, 0x27
jmp 0x4e50bd
cmp dword [ebp - 0x10], 8
lea ecx, [ebp - 0x24]
mov eax, esi
cmovae ecx, dword [ebp - 0x24]
or eax, 0x1c
lea edx, [ebp - 0x24c]
push edx
push ecx
push 0
push 0
push eax
push 0
call sub.SHELL32.dll_SHGetFolderPathAndSubDirW
test eax, eax
je 0x4e5126
test edi, edi
jne 0x4e50fc
cmp dword [ebp - 0x10], 8
lea ecx, [ebp - 0x24c]
push ecx
lea eax, [ebp - 0x24]
cmovae eax, dword [ebp - 0x24]
or esi, 0x23
push eax
push edi
push edi
push esi
push edi
call sub.SHELL32.dll_SHGetFolderPathAndSubDirW
test eax, eax
je 0x4e5126
mov ecx, dword [ebp + 8]
push 0
push 0x75cfea
call fcn.004e4b80
lea ecx, [ebp - 0x24]
call fcn.00484ba0
mov eax, dword [ebp + 8]
pop edi
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp + 8]
lea ecx, [ebp - 0x24c]
xor eax, eax
lea edx, [ecx + 2]
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4e5150
sub ecx, edx
lea eax, [ebp - 0x24c]
sar ecx, 1
push ecx
push eax
mov ecx, esi
call fcn.00486be0
lea ecx, [ebp - 0x24]
call fcn.00484ba0
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
call fcn.0070f5b4
int3