Function at 0x50b7c0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x1fc
push ebp
push esi
mov ebp, ecx
call fcn.0050b3b0
mov eax, dword [ebp + 0x60]
xor esi, esi
cmp eax, esi
jne 0x50b7fe
call dword [sym.imp.USER32.dll_CreatePopupMenu]
push eax
mov dword [ebp + 0x60], eax
call fcn.00486e10
mov eax, dword [ebp + 0x60]
add esp, 4
cmp eax, esi
jne 0x50b7fe
pop esi
xor eax, eax
pop ebp
add esp, 0x1fc
ret 8
mov eax, dword [esp + 0x20c]
lea ecx, [esp + 0x14]
push edi
mov edi, dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
push ecx
push esi
push esi
mov dword [ebp + 0x4c], eax
mov dword [esp + 0x24], esi
mov dword [esp + 0x20], esi
call edi
test eax, eax
jl 0x50b9f3
mov eax, dword [esp + 0x20c]
lea edx, [esp + 0x14]
push edx
push eax
push esi
call edi
test eax, eax
jl 0x50b9f3
mov ecx, 0x3a
xor eax, eax
lea edi, [esp + 0x120]
push ebx
rep stosd dword es:[edi], eax
mov ecx, dword [ebp + 0x58]
mov eax, dword [ebp + 0x68]
add ecx, 0x2710
lea ebx, [ebp + 0x64]
mov dword [esp + 0x128], esi
mov dword [esp + 0x12c], esi
mov dword [esp + 0x134], esi
mov dword [esp + 0x38], ecx
mov ecx, 0x3a
lea esi, [esp + 0x124]
lea edi, [esp + 0x3c]
mov dword [esp + 0x124], 0x123fa
rep movsd dword es:[edi], dword [esi]
mov esi, dword [eax + 4]
mov ecx, dword [0x55f54c]
mov edx, dword [esp + 0x38]
mov edi, eax
cmp esi, ecx
mov al, 1
je 0x50b8c4
mov eax, dword [esi + 0xc]
mov edi, esi
cmp edx, eax
setl al
test al, al
je 0x50b8bd
mov esi, dword [esi]
jmp 0x50b8c0
mov esi, dword [esi + 8]
cmp esi, ecx
jne 0x50b8ab
mov cl, byte [ebx + 8]
test cl, cl
je 0x50b8ee
lea edx, [esp + 0x13]
lea eax, [esp + 0x38]
push edx
push eax
push edi
lea ecx, [esp + 0x40]
push esi
push ecx
mov ecx, ebx
mov byte [esp + 0x27], 1
call fcn.0050fa50
push eax
jmp 0x50b971
test al, al
mov dword [esp + 0x14], edi
je 0x50b939
lea edx, [esp + 0x2c]
mov ecx, ebx
push edx
call fcn.00524430
mov ecx, dword [esp + 0x14]
mov edx, dword [eax]
cmp ecx, edx
jne 0x50b92c
lea edx, [esp + 0x12]
lea eax, [esp + 0x38]
push edx
push eax
push edi
lea ecx, [esp + 0x3c]
push esi
push ecx
mov ecx, ebx
mov byte [esp + 0x26], 1
call fcn.0050fa50
push eax
jmp 0x50b971
lea ecx, [esp + 0x14]
call fcn.005100a0
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x14]
cmp dword [eax + 0xc], edx
jge 0x50b962
lea ecx, [esp + 0x10]
lea edx, [esp + 0x38]
push ecx
push edx
push edi
lea eax, [esp + 0x34]
push esi
push eax
mov ecx, ebx
mov byte [esp + 0x24], 1
call fcn.0050fa50
push eax
jmp 0x50b971
lea ecx, [esp + 0x11]
lea edx, [esp + 0x14]
push ecx
mov byte [esp + 0x15], 0
push edx
lea ecx, [esp + 0x28]
call fcn.004f7560
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
mov dword [eax + 0x14], ecx
mov edx, dword [esp + 0x18]
lea esi, [eax + 0x10]
mov eax, dword [esp + 0x1c]
push edx
push eax
call fcn.00517390
mov dword [esi + 8], eax
mov ecx, dword [ebp + 0x60]
mov eax, dword [esp + 0x218]
mov dword [esi + 0x18], ecx
mov ecx, dword [ebp + 0x58]
add esp, 8
inc ecx
test eax, eax
mov dword [ebp + 0x58], ecx
pop ebx
jne 0x50b9d0
mov eax, dword [ebp + 0x5c]
lea ecx, [esi + 0x10]
push ecx
mov ecx, dword [esi + 4]
mov edx, dword [eax]
push 0x543354
push 0
push ecx
push eax
call dword [edx + 0x14]
jmp 0x50b9e8
mov edx, dword [esp + 0x14]
add esi, 0x10
push 0
push esi
push 0x543354
push edx
call fcn.0050c7c0
add esp, 0x10
mov eax, dword [ebp + 0x60]
mov ecx, ebp
push eax
call fcn.0050bbd0
pop edi
pop esi
mov eax, 1
pop ebp
add esp, 0x1fc
ret 8