Function at 0x561ea0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5b02c3
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push ebx
push esi
push edi
mov eax, dword [0x616040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x18], esi
push 0xa0009
mov edx, esi
lea ecx, [ebp - 0x20]
call fcn.0058f590
add esp, 4
mov dword [ebp - 4], 0
mov ebx, dword [ebp - 0x20]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
or edi, 0xffffffff
test eax, eax
jne 0x5620ec
call fcn.00414e1f
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x561f17
push 0x80004005
call fcn.00402740
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea edi, [eax + 0x10]
mov dword [ebp - 0x1c], edi
mov byte [ebp - 4], 1
mov ecx, 1
mov eax, dword [edi - 8]
sub ecx, dword [edi - 4]
sub eax, 0x104
or eax, ecx
jge 0x561f4c
push 0x104
lea ecx, [ebp - 0x1c]
call fcn.00402c20
mov edi, dword [ebp - 0x1c]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push dword [edi - 8]
push edi
call fcn.00528e42
add esp, 8
test eax, eax
js 0x562134
cmp eax, dword [edi - 8]
jg 0x562134
xor ecx, ecx
mov dword [edi - 0xc], eax
mov word [edi + eax*2], cx
call fcn.00414e1f
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x561f9a
push 0x80004005
call fcn.00402740
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x14], esi
mov byte [ebp - 4], 2
mov ecx, 1
mov eax, dword [esi - 8]
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x561fcf
push 0x104
lea ecx, [ebp - 0x14]
call fcn.00402c20
mov esi, dword [ebp - 0x14]
push 0x104
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
push dword [esi - 8]
push esi
call fcn.00528e42
add esp, 8
test eax, eax
js 0x562134
cmp eax, dword [esi - 8]
jg 0x562134
mov dword [esi - 0xc], eax
xor ecx, ecx
mov word [esi + eax*2], cx
mov ecx, 1
mov eax, dword [esi - 8]
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x562026
push 0x104
lea ecx, [ebp - 0x14]
call fcn.00402c20
mov esi, dword [ebp - 0x14]
push esi
call dword [sym.imp.SHLWAPI.dll_PathRemoveBackslashW]
push dword [esi - 8]
push esi
call fcn.00528e42
add esp, 8
test eax, eax
js 0x562134
cmp eax, dword [esi - 8]
jg 0x562134
xor ecx, ecx
mov dword [esi - 0xc], eax
xor edx, edx
mov word [esi + eax*2], cx
cmp dword [ebp - 0x18], 0x9fbf1
jne 0x562061
lea edx, [ecx + 1]
mov ecx, dword [0x621a1c]
test ecx, ecx
je 0x56207f
mov eax, dword [esi - 0xc]
inc eax
push eax
push esi
push 0xa0009
push dword [edx*4 + 0x621ebc]
call ecx
push ecx
add esi, 0xfffffff0
mov dword [ebp - 0x24], esp
push esi
mov byte [ebp - 0xd], 1
mov dword [ebp - 0x28], esi
call fcn.00403660
mov edx, dword [ebp - 0x24]
add esp, 4
mov cl, byte [ebp - 0xd]
add eax, 0x10
mov dword [edx], eax
call fcn.00567780
lea eax, [esi + 0xc]
mov byte [ebp - 4], 1
or esi, 0xffffffff
add esp, 4
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x5620c9
mov edx, dword [ebp - 0x28]
push edx
mov ecx, dword [edx]
mov eax, dword [ecx]
call dword [eax + 4]
add edi, 0xfffffff0
mov byte [ebp - 4], 0
mov ecx, esi
lea eax, [edi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x5620e6
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [ebp - 0x18]
or edi, 0xffffffff
xor eax, eax
cmp esi, 0x9fbf1
jne 0x5620fb
mov eax, 1
mov ecx, dword [0x621a6c]
test ecx, ecx
je 0x562175
push 0x50000
push dword [eax*4 + 0x621ebc]
call ecx
test eax, eax
jns 0x562175
xor eax, eax
cmp esi, 0x9fbf1
jne 0x562126
mov eax, 1
mov ecx, dword [0x621a6c]
test ecx, ecx
jne 0x56213e
xor edx, edx
jmp 0x56214e
push 0x80070057
call fcn.00402740
push 0x10001
push dword [eax*4 + 0x621ebc]
call ecx
mov edx, eax
xor ecx, ecx
cmp esi, 0x9fbf1
jne 0x56215d
mov ecx, 1
mov eax, dword [0x621a3c]
test eax, eax
je 0x562175
push edx
push 0x50000
push dword [ecx*4 + 0x621ebc]
call eax
add ebx, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [ebx + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x562193
mov ecx, dword [ebx]
push ebx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret