Function at 0x457850
Capabilities:
Check if file exists
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x4951b1
mov eax, dword fs:[0]
push eax
sub esp, 0x62c
mov eax, dword [0x4bd450]
xor eax, esp
mov dword [esp + 0x628], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4bd450]
xor eax, esp
push eax
lea eax, [esp + 0x640]
mov dword fs:[0], eax
xor eax, eax
mov edi, ecx
push 0x206
push eax
lea ecx, [esp + 0x236]
push ecx
mov dword [esp + 0x24], edi
mov word [esp + 0x238], ax
call fcn.00476ef0
add esp, 0xc
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x43e]
push eax
mov word [esp + 0x440], dx
call fcn.00476ef0
add esp, 0xc
xor ecx, ecx
push 0x206
push ecx
lea edx, [esp + 0x2e]
push edx
mov word [esp + 0x30], cx
call fcn.00476ef0
mov esi, dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
add esp, 0xc
push 0
push 0
lea eax, [esp + 0x234]
push eax
push 0
call esi
test eax, eax
je 0x457919
push 0
push 0x19
lea ecx, [esp + 0x43c]
push ecx
push 0
call esi
test eax, eax
jne 0x457920
xor eax, eax
jmp 0x457b57
xor ebx, ebx
mov esi, 0x4be9c0
push str..lnk
push esi
lea edx, [esp + 0x234]
push edx
lea eax, [esp + 0x30]
push str._s_s_s
push eax
mov ecx, 0x104
call fcn.00404a10
add esp, 0x14
test eax, eax
jl 0x4579cf
mov ebp, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
lea ecx, [esp + 0x24]
push ecx
call ebp
test eax, eax
jne 0x457995
push str..lnk
push esi
lea edx, [esp + 0x43c]
push edx
lea eax, [esp + 0x30]
push str._s_s_s
push eax
mov ecx, 0x104
call fcn.00404a10
add esp, 0x14
test eax, eax
jl 0x4579cf
lea ecx, [esp + 0x24]
push ecx
call ebp
test eax, eax
je 0x4579cf
mov dl, bl
add dl, 0x61
movzx eax, dl
push eax
lea ecx, [esp + 0x20]
push ecx
call fcn.00458350
add esp, 8
mov dword [esp + 0x648], 0
call fcn.00431800
mov dword [esp + 0x648], 0xffffffff
lea ecx, [esp + 0x1c]
call fcn.00404e20
inc ebx
add esi, 0x40
cmp ebx, 9
jb 0x457927
mov dword [esp + 0x14], 0
mov ebx, str.u.m
mov dword [esp + 0x1c], 3
cmp dword [0x512470], 0
je 0x457a01
mov esi, ebx
call fcn.00451c20
push str..lnk
push ebx
lea edx, [esp + 0x234]
push edx
lea eax, [esp + 0x30]
push str._s_s_s
push eax
mov ecx, 0x104
call fcn.00404a10
add esp, 0x14
test eax, eax
jl 0x457b37
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
lea ecx, [esp + 0x24]
push ecx
call esi
test eax, eax
jne 0x457a7b
push str..lnk
push ebx
lea edx, [esp + 0x43c]
push edx
lea eax, [esp + 0x30]
push str._s_s_s
push eax
mov ecx, 0x104
call fcn.00404a10
add esp, 0x14
test eax, eax
jl 0x457b37
lea ecx, [esp + 0x24]
push ecx
call esi
test eax, eax
je 0x457b37
mov edx, dword [esp + 0x14]
push edx
lea ecx, [esp + 0x28]
call fcn.00457b80
test eax, eax
je 0x457b37
mov al, byte [esp + 0x14]
add al, 0x72
movzx ecx, al
push ecx
lea edx, [esp + 0x24]
push edx
call fcn.00458350
add esp, 8
mov dword [esp + 0x648], 1
mov ecx, dword [eax]
mov ebp, dword [edi]
lea eax, [ecx - 0x10]
sub ebp, 0x10
cmp eax, ebp
je 0x457b08
cmp dword [ebp + 0xc], 0
lea esi, [ebp + 0xc]
jl 0x457afa
mov edx, dword [eax]
cmp edx, dword [ebp]
jne 0x457afa
call fcn.004082e0
mov edi, eax
or eax, 0xffffffff
lock xadd dword [esi], eax
dec eax
test eax, eax
jg 0x457aef
mov ecx, dword [ebp]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push ebp
call eax
mov ecx, dword [esp + 0x18]
add edi, 0x10
mov dword [ecx], edi
jmp 0x457b08
mov eax, dword [ecx - 0xc]
push eax
mov eax, dword [esp + 0x1c]
push ecx
call fcn.004086f0
mov dword [esp + 0x648], 0xffffffff
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x457b33
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [esp + 0x18]
mov eax, 1
add dword [esp + 0x14], eax
add ebx, 0x28
sub dword [esp + 0x1c], eax
jne 0x4579f1
mov dword [0x512470], 0
mov ecx, dword [esp + 0x640]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x628]
xor ecx, esp
call fcn.00471eba
add esp, 0x638
ret