Function at 0x40ac40
Capabilities:
Get common file path

Disassembly:
push ebp
lea ebp, [esp - 0x628]
sub esp, 0x628
push 0xffffffffffffffff
push 0x41f368
mov eax, dword fs:[0]
push eax
sub esp, 0x18
mov eax, dword [0x42a008]
xor eax, ebp
mov dword [ebp + 0x624], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
push 0x42b7cc
lea ecx, [ebp]
mov dword [ebp], 0
call fcn.004027be
mov dword [ebp - 4], 0
mov ecx, 0x42b7a8
call fcn.004021e4
test al, al
jne 0x40ae55
call fcn.0040192d
cmp esi, eax
je 0x40ae3f
call fcn.0040192d
mov edx, eax
mov dword [ebp - 0x14], eax
cmp dword [eax + 0x14], 8
jb 0x40acca
mov edx, dword [eax]
mov dword [ebp - 0x14], edx
mov ebx, dword [eax + 0x10]
mov ecx, esi
call fcn.0040192d
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x18], eax
cmp ebx, eax
ja 0x40ad0e
mov esi, edi
cmp eax, 8
jb 0x40ace9
mov esi, dword [edi]
push ebx
mov ecx, esi
mov dword [edi + 0x10], ebx
call fcn.0040195b
add esp, 4
mov dword [ebp - 0x14], 0
lea ecx, [esi + ebx*2]
lea edx, [ebp - 0x14]
call fcn.00401a21
jmp 0x40ae3f
call fcn.00401c1b
cmp ebx, eax
ja 0x40b173
call fcn.00401c1b
mov edx, eax
mov ecx, esi
mov dword [ebp - 0x1c], edx
call fcn.0040192d
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x24], ecx
cmp ecx, edx
ja 0x40ad5d
mov esi, dword [eax + 0x14]
mov ecx, esi
shr ecx, 1
mov eax, edx
sub eax, ecx
cmp esi, eax
ja 0x40ad5a
lea eax, [ecx + esi]
lea edx, [ebp - 0x20]
mov dword [ebp - 0x20], eax
lea ecx, [ebp - 0x24]
call fcn.004014a4
mov edx, dword [eax]
mov dword [ebp - 0x1c], edx
lea eax, [edx + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x40ad6f
or ecx, 0xffffffff
jmp 0x40ad77
cmp ecx, 0x1000
jb 0x40ada3
lea eax, [ecx + 0x23]
or edx, 0xffffffff
cmp eax, ecx
cmovbe eax, edx
push eax
call fcn.0040c4bd
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x40b178
mov edx, dword [ebp - 0x1c]
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x40adb7
test ecx, ecx
je 0x40adb5
push ecx
call fcn.0040c4bd
mov edx, dword [ebp - 0x1c]
add esp, 4
jmp 0x40adb7
xor eax, eax
mov dword [ebp - 0x10], eax
mov dword [edi + 0x14], edx
mov edx, dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
mov esi, dword [ebp - 0x10]
mov ecx, esi
push ebx
call fcn.00401a28
add esp, 4
mov dword [ebp - 0x14], 0
lea ecx, [esi + ebx*2]
lea edx, [ebp - 0x14]
call fcn.00401a21
mov ecx, dword [ebp - 0x18]
cmp ecx, 8
jb 0x40ae23
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x40ae12
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40b178
mov eax, edx
push ecx
push eax
call fcn.0040c4ed
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
jmp 0x40ae3f
mov ecx, edi
call fcn.0040192d
mov edx, eax
call fcn.004013f0
lea ecx, [ebp - 0x10]
mov edx, eax
call fcn.0040192d
mov ecx, dword [eax]
mov dword [edx], ecx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.004027e1
mov al, 1
jmp 0x40b150
push 0x20c
lea eax, [ebp + 0x418]
push 0
push eax
call fcn.0040e2f0
add esp, 0xc
lea eax, [ebp + 0x418]
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
dec eax
cmp eax, 0x103
ja 0x40b13f
xor eax, eax
push 0x412
push eax
mov word [ebp + 0x622], ax
lea eax, [ebp + 4]
push eax
call fcn.0040e2f0
add esp, 0xc
lea eax, [ebp + 4]
push 0x208
push eax
lea eax, [ebp + 0x418]
push eax
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
cmp eax, 0x208
ja 0x40afde
test eax, eax
je 0x40afde
add eax, eax
cmp eax, 0x412
jae 0x40b182
xor ecx, ecx
mov word [ebp + eax + 4], cx
lea ecx, [ebp + 4]
call fcn.00401970
mov ecx, esi
mov ebx, eax
call fcn.0040192d
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x1c], eax
cmp ebx, eax
ja 0x40af2f
mov esi, edi
cmp eax, 8
jb 0x40af07
mov esi, dword [edi]
push ebx
lea edx, [ebp + 4]
mov dword [edi + 0x10], ebx
mov ecx, esi
call fcn.0040195b
add esp, 4
mov dword [ebp - 0x18], 0
lea ecx, [esi + ebx*2]
lea edx, [ebp - 0x18]
call fcn.00401a21
jmp 0x40ae3f
call fcn.00401c1b
cmp ebx, eax
ja 0x40b17d
call fcn.00401c1b
mov esi, eax
call fcn.0040192d
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x24], ecx
cmp ecx, esi
ja 0x40af76
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x40af76
lea eax, [ecx + edx]
lea edx, [ebp - 0x18]
mov dword [ebp - 0x18], eax
lea ecx, [ebp - 0x24]
call fcn.004014a4
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x40af88
or ecx, 0xffffffff
jmp 0x40af90
cmp ecx, 0x1000
jb 0x40afbf
lea eax, [ecx + 0x23]
or edx, 0xffffffff
cmp eax, ecx
cmovbe eax, edx
push eax
call fcn.0040c4bd
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x40b178
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
lea edx, [ebp + 4]
mov dword [eax - 4], ecx
jmp 0x40b0d3
test ecx, ecx
je 0x40afd4
push ecx
call fcn.0040c4bd
add esp, 4
lea edx, [ebp + 4]
jmp 0x40b0d3
xor eax, eax
lea edx, [ebp + 4]
jmp 0x40b0d3
lea ecx, [ebp + 0x418]
call fcn.00401970
mov ecx, esi
mov ebx, eax
call fcn.0040192d
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x1c], eax
cmp ebx, eax
ja 0x40b032
mov esi, edi
cmp eax, 8
jb 0x40b007
mov esi, dword [edi]
push ebx
lea edx, [ebp + 0x418]
mov dword [edi + 0x10], ebx
mov ecx, esi
call fcn.0040195b
add esp, 4
mov dword [ebp - 0x18], 0
lea ecx, [esi + ebx*2]
lea edx, [ebp - 0x18]
call fcn.00401a21
jmp 0x40ae3f
call fcn.00401c1b
cmp ebx, eax
ja 0x40b187
call fcn.00401c1b
mov esi, eax
call fcn.0040192d
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x24], ecx
cmp ecx, esi
ja 0x40b079
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x40b079
lea eax, [edx + ecx]
lea edx, [ebp - 0x18]
mov dword [ebp - 0x18], eax
lea ecx, [ebp - 0x24]
call fcn.004014a4
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x40b08b
or ecx, 0xffffffff
jmp 0x40b093
cmp ecx, 0x1000
jb 0x40b0bc
lea eax, [ecx + 0x23]
or edx, 0xffffffff
cmp eax, ecx
cmovbe eax, edx
push eax
call fcn.0040c4bd
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x40b178
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x40b0cd
test ecx, ecx
je 0x40b0cb
push ecx
call fcn.0040c4bd
add esp, 4
jmp 0x40b0cd
xor eax, eax
lea edx, [ebp + 0x418]
mov dword [ebp - 0x10], eax
mov dword [edi + 0x10], ebx
mov dword [edi + 0x14], esi
mov esi, dword [ebp - 0x10]
mov ecx, esi
push ebx
call fcn.00401a28
add esp, 4
mov dword [ebp - 0x20], 0
lea edx, [ebp - 0x20]
lea ecx, [esi + ebx*2]
call fcn.00401a21
mov ecx, dword [ebp - 0x1c]
cmp ecx, 8
jb 0x40ae23
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x40b12b
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40b178
mov eax, edx
push ecx
push eax
call fcn.0040c4ed
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
jmp 0x40ae3f
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.004027e1
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x624]
xor ecx, ebp
call fcn.0040c4a7
lea esp, [ebp + 0x628]
pop ebp
ret
call fcn.00401632
call fcn.004112e6
call fcn.00401632
call fcn.0040cc2b
call fcn.00401632
int3