Function at 0x5d1550
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
lea esp, [esp - 0x2b0]
push ebx
mov dword [ebp - 8], eax
mov dword [ebp - 4], edx
mov edx, 0x6bea18
lea eax, [ebp - 0x1c]
call fcn.0040f830
mov dword [ebp - 0x298], 0
mov dword [ebp - 0x284], 0
mov eax, 1
lea edx, [ebp - 0x254]
lea ecx, [ebp - 0x23c]
call fcn.0040e9e0
call fcn.00404380
push eax
test eax, eax
jne 0x5d17ca
call fcn.005774c0
mov cl, 8
mov edx, str.AddUsingCLSIDs
call fcn.005778d0
mov eax, 1
lea edx, [ebp - 0x27c]
lea ecx, [ebp - 0x264]
call fcn.0040e9e0
call fcn.00404380
push eax
test eax, eax
jne 0x5d17aa
mov dword [ebp - 0xc], 0xffffffff
lea esi, [esi]
add dword [ebp - 0xc], 1
mov ecx, 0x6bea18
mov eax, dword [ebp - 0xc]
imul eax, eax, 0xc
lea eax, [eax + 0x625aa0]
lea edx, [ebp - 0x1c]
call fcn.0040fdb0
cmp dword [ebp - 0x1c], 0xffffffff
jle 0x5d17a0
mov dword [ebp - 0x20], 0
cmp dword [0x6c7e54], 6
jae 0x5d16fe
lea eax, [ebp - 0x230]
push eax
push 0
push dword [ebp - 4]
push dword [ebp - 0x1c]
push 0
call sub.shell32.dll_SHGetFolderPathW
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x5d1690
call fcn.005774c0
mov cl, 8
mov edx, str.SHGetFolderPathW__S_OK
call fcn.00577de0
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 8]
call fcn.005d1a00
mov dword [ebp - 0x24], eax
push 1
lea eax, [ebp - 0x284]
push eax
lea eax, [ebp - 0x230]
xor cx, cx
mov edx, 0x104
call fcn.0040c0a0
mov edx, dword [ebp - 0x284]
mov eax, dword [ebp - 0x24]
xor cl, cl
call fcn.005d1f90
jmp 0x5d17a0
call fcn.005774c0
mov ebx, eax
lea eax, [ebp - 0x284]
push eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x290], eax
mov dword [ebp - 0x294], 0
mov eax, dword [ebp - 0x10]
lea edx, [ebp - 0x298]
call fcn.004223d0
mov eax, dword [ebp - 0x298]
mov dword [ebp - 0x288], eax
mov dword [ebp - 0x28c], 0xb
lea edx, [ebp - 0x294]
mov ecx, 1
mov eax, str.SHGetFolderPathW____d___s
call fcn.00417e20
mov edx, dword [ebp - 0x284]
mov cl, 4
mov eax, ebx
call fcn.00578940
jmp 0x5d17a0
lea eax, [ebp - 0x20]
push eax
push 0
push dword [ebp - 4]
push dword [ebp - 0x1c]
push 0
call sub.shell32.dll_SHGetFolderLocation
test eax, eax
jne 0x5d17a0
mov eax, 1
lea edx, [ebp - 0x2b0]
lea ecx, [ebp - 0x290]
call fcn.0040e9e0
call fcn.00404380
push eax
test eax, eax
jne 0x5d1788
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 8]
call fcn.005d1a00
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x230]
push eax
push dword [ebp - 0x20]
call sub.shell32.dll_SHGetPathFromIDListW
test eax, eax
je 0x5d1788
push 1
lea eax, [ebp - 0x298]
push eax
lea eax, [ebp - 0x230]
xor cx, cx
mov edx, 0x104
call fcn.0040c0a0
mov edx, dword [ebp - 0x298]
mov eax, dword [ebp - 0x24]
xor cl, cl
call fcn.005d1f90
mov esi, esi
call fcn.0040ec50
push dword [ebp - 0x20]
call sub.shell32.dll_ILFree
pop eax
test eax, eax
je 0x5d179f
call fcn.0040ed80
nop
cmp dword [ebp - 0xc], 0x30
jl 0x5d15e8
call fcn.0040ec50
call fcn.005774c0
mov cl, 8
mov edx, str.AddUsingCLSIDs
call fcn.00577bb0
pop eax
test eax, eax
je 0x5d17ca
call fcn.0040ed80
call fcn.0040ec50
lea eax, [ebp - 0x298]
call fcn.00403ec0
lea eax, [ebp - 0x284]
call fcn.00403ec0
mov edx, 0x6bea18
lea eax, [ebp - 0x1c]
call fcn.0040f8f0
pop eax
test eax, eax
je 0x5d17fc
call fcn.0040ed80
pop ebx
mov esp, ebp
pop ebp
ret