Function at 0x510824
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeb0
push ebx
xor ebx, ebx
mov dword [ebp - 0x150], ebx
mov dword [ebp - 0x14c], ebx
mov dword [ebp - 0x138], ebx
mov dword [ebp - 0x134], ebx
mov dword [ebp - 0x130], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404870
mov eax, dword [ebp - 8]
call fcn.00404870
mov eax, dword [ebp - 0xc]
call fcn.00404870
xor eax, eax
push ebp
push 0x510a91
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 0xd], 0
mov eax, dword [ebp - 4]
call fcn.00409964
test al, al
je 0x510a36
cmp dword [ebp - 8], 0
jne 0x5108c1
lea edx, [ebp - 0x130]
mov eax, dword [ebp - 4]
call fcn.00409d34
mov eax, dword [ebp - 0x130]
lea ecx, [ebp - 8]
xor edx, edx
call fcn.00409c6c
lea edx, [ebp - 0x14]
mov eax, dword [0x606068]
call fcn.00494f18
lea eax, [ebp - 0x18]
mov edx, dword [ebp - 0x14]
mov ecx, 0x510aa4
call fcn.004061f4
mov eax, dword [ebp - 4]
call fcn.00404880
push eax
mov eax, dword [ebp - 0x18]
push eax
mov eax, dword [eax]
call dword [eax + 0x50]
lea edx, [ebp - 0x134]
mov eax, dword [ebp - 4]
call fcn.00409d00
mov eax, dword [ebp - 0x134]
call fcn.00404880
push eax
mov eax, dword [ebp - 0x18]
push eax
mov eax, dword [eax]
call dword [eax + 0x24]
cmp dword [ebp - 0xc], 0
jne 0x510924
cmp dword [ebp + 8], 0xffffffff
jne 0x510924
xor eax, eax
mov dword [ebp + 8], eax
cmp dword [ebp + 8], 0xffffffff
jle 0x510998
lea eax, [ebp - 0x20]
push eax
mov eax, dword [ebp + 8]
push eax
push 0
call sub.shell32.dll_SHGetSpecialFolderLocation
lea eax, [ebp - 0x129]
push eax
mov eax, dword [ebp - 0x20]
push eax
call sub.shell32.dll_SHGetPathFromIDListA
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x129]
mov dword [ebp - 0x148], eax
mov byte [ebp - 0x144], 6
mov eax, dword [ebp - 8]
mov dword [ebp - 0x140], eax
mov byte [ebp - 0x13c], 0xb
lea edx, [ebp - 0x148]
mov ecx, 1
mov eax, 0x510abc
call fcn.0040a55c
mov edx, dword [ebp - 0x138]
lea eax, [ebp - 0x24]
call fcn.00404c44
jmp 0x510a0a
lea edx, [ebp - 0x14c]
mov eax, dword [ebp - 0xc]
call fcn.0040de88
mov edx, dword [ebp - 0x14c]
lea eax, [ebp - 0xc]
call fcn.00404458
mov eax, dword [ebp - 0xc]
call fcn.00409974
test al, al
je 0x510a36
lea eax, [ebp - 0x150]
push eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x148], eax
mov byte [ebp - 0x144], 0xb
mov eax, dword [ebp - 8]
mov dword [ebp - 0x140], eax
mov byte [ebp - 0x13c], 0xb
lea edx, [ebp - 0x148]
mov ecx, 1
mov eax, 0x510abc
call fcn.0040a55c
mov edx, dword [ebp - 0x150]
lea eax, [ebp - 0x24]
call fcn.00404c44
lea eax, [ebp - 0x1c]
mov edx, dword [ebp - 0x14]
mov ecx, 0x510ac8
call fcn.004061f4
push 0
mov eax, dword [ebp - 0x24]
call fcn.00404c54
push eax
mov eax, dword [ebp - 0x1c]
push eax
mov eax, dword [eax]
call dword [eax + 0x18]
test eax, eax
jne 0x510a36
mov byte [ebp - 0xd], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x510a98
lea eax, [ebp - 0x150]
mov edx, 2
call fcn.004043e4
lea eax, [ebp - 0x138]
mov edx, 3
call fcn.004043e4
lea eax, [ebp - 0x24]
call fcn.00404acc
lea eax, [ebp - 0x1c]
call fcn.004061b0
lea eax, [ebp - 0x18]
call fcn.004061b0
lea eax, [ebp - 0x14]
call fcn.004061b0
lea eax, [ebp - 0xc]
mov edx, 3
call fcn.004043e4
ret