Function at 0x401f90
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x550fd7
mov eax, dword fs:[0]
push eax
sub esp, 0x224
mov eax, dword [0x5aa170]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x22c], ecx
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x218], ax
lea eax, [ebp - 0x216]
push eax
call fcn.0052b410
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x224]
call fcn.00404020
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x224]
add eax, 0xfffffff0
push eax
call fcn.004040f0
lea esi, [eax + 0x10]
mov dword [ebp - 0x220], esi
push 0x5c
push esi
mov byte [ebp - 4], 1
call fcn.0052a276
add esp, 0xc
test eax, eax
jne 0x40203f
or eax, 0xffffffff
jmp 0x402043
sub eax, esi
sar eax, 1
inc eax
or edi, 0xffffffff
test eax, eax
jle 0x402093
push eax
push 0
lea eax, [ebp - 0x21c]
push eax
lea ecx, [ebp - 0x220]
call fcn.00403390
push eax
lea ecx, [ebp - 0x224]
mov byte [ebp - 4], 2
call fcn.004038e0
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x21c]
add edx, 0xfffffff0
mov ecx, edi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x402093
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x224]
add esi, 0xfffffff0
lea edx, [eax - 0x10]
cmp edx, esi
je 0x4020f4
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x4020e5
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x4020e5
push edx
call fcn.004040f0
add esp, 4
mov dword [ebp - 0x21c], eax
mov ecx, edi
lock xadd dword [ebx], ecx
dec ecx
test ecx, ecx
jg 0x4020da
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x21c]
add eax, 0x10
mov dword [ebp - 0x220], eax
jmp 0x4020f4
push dword [eax - 0xc]
lea ecx, [ebp - 0x220]
push eax
call fcn.00403ed0
push ecx
lea ecx, [ebp - 0x220]
call fcn.00403330
mov eax, dword [ebp - 0x220]
mov ebx, dword [eax - 0xc]
lea esi, [ebx + 1]
test esi, esi
jns 0x40211a
push 0x80070057
call fcn.004041c0
mov ecx, dword [eax - 8]
mov edx, 1
sub edx, dword [eax - 4]
sub ecx, esi
or ecx, edx
jge 0x40213d
push esi
lea ecx, [ebp - 0x220]
call fcn.00403df0
mov eax, dword [ebp - 0x220]
mov ecx, 0x5c
mov word [eax + ebx*2], cx
cmp esi, dword [eax - 8]
jg 0x402110
xor ecx, ecx
mov dword [eax - 0xc], esi
mov word [eax + esi*2], cx
mov ecx, dword [ebp - 0x224]
lea esi, [eax - 0x10]
lea ebx, [ecx - 0x10]
cmp esi, ebx
je 0x4021bb
cmp dword [ebx + 0xc], 0
jl 0x4021a6
mov ecx, dword [esi]
cmp ecx, dword [ebx]
jne 0x4021a6
push esi
call fcn.004040f0
add esp, 4
mov dword [ebp - 0x21c], eax
mov ecx, edi
lea edx, [ebx + 0xc]
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40219b
mov ecx, dword [ebx]
push ebx
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x21c]
lea ecx, [eax + 0x10]
mov dword [ebp - 0x224], ecx
jmp 0x4021bb
push dword [eax - 0xc]
lea ecx, [ebp - 0x224]
push eax
call fcn.00403ed0
mov ecx, dword [ebp - 0x224]
mov edx, dword [ebp - 0x22c]
lea eax, [ecx - 0x10]
mov ebx, dword [edx + 0x1e8]
sub ebx, 0x10
mov dword [ebp - 0x21c], eax
cmp eax, ebx
je 0x402233
cmp dword [ebx + 0xc], 0
jl 0x402224
mov eax, dword [eax]
cmp eax, dword [ebx]
jne 0x402224
push dword [ebp - 0x21c]
call fcn.004040f0
mov dword [ebp - 0x21c], eax
add esp, 4
mov ecx, edi
lea eax, [ebx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40220d
mov ecx, dword [ebx]
push ebx
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x21c]
mov ecx, dword [ebp - 0x22c]
add eax, 0x10
mov dword [ecx + 0x1e8], eax
jmp 0x402233
push dword [ecx - 0xc]
push ecx
lea ecx, [edx + 0x1e8]
call fcn.00403ed0
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x228]
call fcn.00404020
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x228]
lea edx, [eax - 0x10]
cmp edx, esi
je 0x4022b9
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x4022aa
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x4022aa
push edx
call fcn.004040f0
add esp, 4
mov dword [ebp - 0x21c], eax
mov ecx, edi
lock xadd dword [ebx], ecx
dec ecx
test ecx, ecx
jg 0x40229f
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x21c]
add eax, 0x10
mov dword [ebp - 0x220], eax
jmp 0x4022b9
push dword [eax - 0xc]
lea ecx, [ebp - 0x220]
push eax
call fcn.00403ed0
push ecx
lea ecx, [ebp - 0x220]
call fcn.00403330
lea eax, [ebp - 0x21c]
push eax
call fcn.00402ca0
mov byte [ebp - 4], 4
push dword [eax]
mov esi, dword [ebp - 0x220]
push esi
lea eax, [ebp - 0x228]
push str._s_s_
push eax
call fcn.004039d0
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0x21c]
add edx, 0xfffffff0
add esp, 0x10
lea eax, [edx + 0xc]
mov ecx, edi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x402315
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x22c]
mov eax, dword [ebp - 0x228]
mov ebx, dword [edx + 0x1e4]
lea ecx, [eax - 0x10]
sub ebx, 0x10
mov dword [ebp - 0x230], ecx
cmp ecx, ebx
je 0x402399
cmp dword [ebx + 0xc], 0
jl 0x402384
mov ecx, dword [ecx]
cmp ecx, dword [ebx]
jne 0x402384
push dword [ebp - 0x230]
call fcn.004040f0
mov dword [ebp - 0x230], eax
add esp, 4
mov ecx, edi
lea eax, [ebx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40236d
mov ecx, dword [ebx]
push ebx
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x230]
mov ecx, dword [ebp - 0x22c]
add eax, 0x10
mov dword [ecx + 0x1e4], eax
jmp 0x402393
push dword [eax - 0xc]
lea ecx, [edx + 0x1e4]
push eax
call fcn.00403ed0
mov eax, dword [ebp - 0x228]
lea edx, [eax - 0x10]
mov byte [ebp - 4], 1
lea eax, [edx + 0xc]
mov ecx, edi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4023b6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 0xfffffff0
mov byte [ebp - 4], 0
lea eax, [esi + 0xc]
mov ecx, edi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4023d3
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x224]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x4023f7
mov ecx, dword [edx]
push edx
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 ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00529711
mov esp, ebp
pop ebp
ret