Function at 0x4f5018
Capabilities:
Get common file path

Disassembly:
push 0x14
mov eax, 0x598e85
call fcn.00584f68
push 0x5c
push dword [ebp + 8]
call dword [sym.imp.MSVCR80.dll_strchr]
test eax, eax
pop ecx
pop ecx
jne 0x4f5199
cmp byte [0x611e50], al
mov ebx, 0x611e50
mov edi, 0x611a50
jne 0x4f50b4
mov esi, 0x400
push esi
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0x5c
push ebx
call dword [sym.imp.MSVCR80.dll_strrchr]
test eax, eax
pop ecx
pop ecx
je 0x4f506c
mov byte [eax + 1], 0
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jbe 0x4f508e
lea ecx, [eax + 0x611a50]
cmp byte [ecx - 1], 0x5c
je 0x4f508e
mov byte [ecx], 0x5c
mov byte [eax + 0x611a51], 0
push esi
push 0x611650
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jbe 0x4f50b4
lea ecx, [eax + 0x611650]
cmp byte [ecx - 1], 0x5c
je 0x4f50b4
mov byte [ecx], 0x5c
mov byte [eax + 0x611651], 0
push edi
lea ecx, [ebp - 0x18]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::constructor_char_const__
push dword [ebp + 8]
and dword [ebp - 4], 0
push eax
lea eax, [ebp - 0x14]
push eax
call sym.txupd.exe_class_CTXStringA___cdecl_operator_class_CTXStringA_const___char_const__
add esp, 0xc
mov ecx, eax
call sym.txupd.exe_public:_char_const____thiscall_CTXStringA::operator_char_const__void_const
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push eax
call esi
mov edi, eax
test edi, edi
lea ecx, [ebp - 0x14]
sete byte [ebp - 0xd]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x18]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
cmp byte [ebp - 0xd], 0
je 0x4f51a4
push 0x611650
lea ecx, [ebp - 0x14]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::constructor_char_const__
push dword [ebp + 8]
mov dword [ebp - 4], 1
push eax
lea eax, [ebp - 0x18]
push eax
call sym.txupd.exe_class_CTXStringA___cdecl_operator_class_CTXStringA_const___char_const__
add esp, 0xc
mov ecx, eax
call sym.txupd.exe_public:_char_const____thiscall_CTXStringA::operator_char_const__void_const
push eax
call esi
mov edi, eax
test edi, edi
lea ecx, [ebp - 0x18]
sete byte [ebp - 0xd]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
cmp byte [ebp - 0xd], 0
je 0x4f51a4
push ebx
lea ecx, [ebp - 0x20]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::constructor_char_const__
push dword [ebp + 8]
mov dword [ebp - 4], 2
push eax
lea eax, [ebp - 0x1c]
push eax
call sym.txupd.exe_class_CTXStringA___cdecl_operator_class_CTXStringA_const___char_const__
add esp, 0xc
mov ecx, eax
call sym.txupd.exe_public:_char_const____thiscall_CTXStringA::operator_char_const__void_const
push eax
call esi
lea ecx, [ebp - 0x1c]
mov edi, eax
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call sym.txupd.exe_public:_void___thiscall_CTXStringA::destructor_void_
jmp 0x4f51a4
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
mov eax, edi
call fcn.00585040
ret