Function at 0x4507e0
Capabilities:
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x4ac450
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xc50
push ebx
push ebp
push esi
mov dword [esp + 0x20], ecx
push edi
xor ebx, ebx
mov ecx, 0x82
xor eax, eax
lea edi, [esp + 0x4a]
mov word [esp + 0x48], bx
rep stosd dword es:[edi], eax
lea eax, [esp + 0x48]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov ebp, dword [sym.imp.MSVCRT.dll_wcslen]
lea ecx, [esp + 0x48]
push ecx
call ebp
add esp, 4
lea edx, [esp + 0x48]
mov ecx, 0x4d1540
push eax
push edx
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
mov ecx, dword [0x4d3034]
mov esi, dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [esp + 0x48]
push 0x104
push eax
push ecx
mov word [esp + 0x54], bx
call esi
lea edx, [esp + 0x48]
push 0x5c
push edx
call dword [sym.imp.MSVCRT.dll_wcsrchr]
add esp, 8
cmp eax, ebx
je 0x450896
mov word [eax], bx
cmp word [esp + 0x48], bx
jne 0x45089d
push 0x4c0d8c
call ebp
add esp, 4
push eax
push 0x4c0d8c
jmp 0x4508ad
mov word [esp + 0x48], bx
jmp 0x450884
lea eax, [esp + 0x48]
push eax
call ebp
add esp, 4
lea ecx, [esp + 0x48]
push eax
push ecx
mov ecx, 0x4d1288
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
mov dl, byte [esp + 0x13]
push ebx
lea ecx, [esp + 0x2c]
mov byte [esp + 0x2c], dl
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
mov ecx, 0x82
xor eax, eax
lea edi, [esp + 0x256]
mov word [esp + 0x254], bx
rep stosd dword es:[edi], eax
lea eax, [esp + 0x254]
push 0x104
push eax
push ebx
mov dword [esp + 0xc74], ebx
call esi
lea ecx, [esp + 0x254]
xor edi, edi
push ecx
call ebp
add esp, 4
test eax, eax
jbe 0x45093c
mov ebx, dword [sym.imp.MSVCRT.dll_tolower]
lea esi, [esp + 0x254]
xor edx, edx
mov dx, word [esi]
push edx
call ebx
mov word [esi], ax
lea eax, [esp + 0x258]
push eax
inc edi
add esi, 2
call ebp
add esp, 8
cmp edi, eax
jb 0x45091a
xor ebx, ebx
lea ecx, [esp + 0x254]
push 0x5c
push ecx
call dword [sym.imp.MSVCRT.dll_wcsrchr]
add esp, 8
cmp eax, ebx
je 0x450a86
mov dl, byte [esp + 0x13]
push ebx
lea ecx, [esp + 0x18]
lea edi, [eax + 2]
mov byte [esp + 0x18], dl
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
push edi
call ebp
add esp, 4
mov esi, eax
lea ecx, [esp + 0x14]
push 1
push esi
call dword [sym.imp.MSVCP60.dll_private:_bool___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Grow_unsigned_int__bool_]
test al, al
je 0x4509a0
mov eax, dword [esp + 0x18]
push esi
push edi
push eax
call fcn.00411a90
add esp, 0xc
lea ecx, [esp + 0x14]
push esi
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Eos_unsigned_int_]
push 0x4c0d8c
mov byte [esp + 0xc6c], 1
call ebp
add esp, 4
lea ecx, [esp + 0x14]
push eax
push ebx
push 0x4c0d8c
call dword [sym.imp.MSVCP60.dll_public:_unsigned_int___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::find_unsigned_short_int_const___unsigned_int__unsigned_int_const]
mov ecx, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
cmp eax, dword [ecx]
je 0x450a72
push eax
lea edx, [esp + 0x3c]
push ebx
push edx
lea ecx, [esp + 0x20]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int_____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::substr_unsigned_int__unsigned_int_]
mov ecx, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
mov byte [esp + 0xc68], 2
mov edx, dword [ecx]
lea ecx, [esp + 0x14]
push edx
push ebx
push eax
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_int__unsigned_int_]
push 1
lea ecx, [esp + 0x3c]
mov byte [esp + 0xc6c], 1
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
lea eax, [esp + 0x14]
push 0x4c53e8
push eax
call dword [sym.imp.MSVCP60.dll_bool___cdecl_std::operator__class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_short_int_const__]
add esp, 8
test al, al
je 0x450a72
lea ecx, [esp + 0x14]
lea edx, [esp + 0x38]
push ecx
push 0x4c53e4
push edx
call sub.MSVCP60.dll_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int_____cdecl_std::operator_unsigned_short_int_const___class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const__
add esp, 0xc
mov ecx, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
mov byte [esp + 0xc68], 3
mov edx, dword [ecx]
lea ecx, [esp + 0x28]
push edx
push ebx
push eax
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_int__unsigned_int_]
push 1
lea ecx, [esp + 0x3c]
mov byte [esp + 0xc6c], 1
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
push 1
lea ecx, [esp + 0x18]
mov byte [esp + 0xc6c], 0
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
mov ecx, dword [esp + 0x2c]
mov edx, dword [sym.imp.MSVCP60.dll_unsigned_short_int_const__private:_static_unsigned_short_int_const____cdecl_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Nullstr_void_::_2::_C]
cmp ecx, ebx
jne 0x450a96
mov ecx, edx
mov eax, dword [0x4d128c]
cmp eax, ebx
jne 0x450aa1
mov eax, edx
push ecx
push eax
lea eax, [esp + 0x50]
push str._sLiveUpdateLogP2SP_s.log
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea ecx, [esp + 0x48]
push ecx
mov ecx, 0x4d1048
call fcn.00453750
call fcn.00459730
cmp eax, 4
jae 0x450ad4
mov dword [0x4d104c], eax
lea edx, [esp + 0x460]
push 0x800
push edx
push str.360P2SP.dll
mov dword [0x4d1048], 1
call fcn.00459d20
lea eax, [esp + 0x46c]
push eax
call ebp
add esp, 0x10
mov ecx, 0x4d1220
mov esi, eax
call dword [sym.imp.MSVCP60.dll_public:_unsigned_int___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::max_size_void_const]
cmp eax, esi
jae 0x450b19
call dword [sym.imp.MSVCP60.dll_void___cdecl_std::_Xlen_void_]
mov eax, dword [0x4d1224]
cmp eax, ebx
je 0x450b45
mov cl, byte [eax - 1]
test cl, cl
je 0x450b45
cmp cl, 0xff
je 0x450b45
cmp esi, ebx
jne 0x450b74
dec cl
push ebx
mov byte [eax - 1], cl
mov ecx, 0x4d1220
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
jmp 0x450ba7
cmp esi, ebx
jne 0x450b58
push 1
mov ecx, 0x4d1220
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
jmp 0x450ba7
mov ecx, dword [0x4d122c]
cmp ecx, 0x1f
ja 0x450b67
cmp ecx, esi
jae 0x450b85
push 1
mov ecx, 0x4d1220
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
push esi
mov ecx, 0x4d1220
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Copy_unsigned_int_]
mov eax, dword [0x4d1224]
lea ecx, [esp + 0x460]
push esi
push ecx
push eax
call fcn.00411a90
mov edx, dword [0x4d1224]
mov dword [0x4d1228], esi
add esp, 0xc
mov word [edx + esi*2], bx
mov ecx, dword [esp + 0x24]
call fcn.00450c10
mov ecx, dword [esp + 0x2c]
pop edi
pop esi
pop ebp
cmp ecx, ebx
pop ebx
je 0x450bed
mov al, byte [ecx - 1]
test al, al
je 0x450be1
cmp al, 0xff
je 0x450be1
dec al
mov byte [ecx - 1], al
mov ecx, dword [esp + 0xc50]
mov dword fs:[0], ecx
add esp, 0xc5c
ret
add ecx, 0xfffffffe
push ecx
call fcn.0049c000
add esp, 4
mov ecx, dword [esp + 0xc50]
mov dword fs:[0], ecx
add esp, 0xc5c
ret