Function at 0x406906
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push ebx
push esi
push edi
mov dword [ebp - 8], 0
mov dword [ebp - 0x34], 0
mov dword [0x5a3050], 0
jmp 0x406932
inc dword [0x5a3050]
cmp dword [0x5a3050], 0x3000
jge 0x406953
mov eax, dword [0x5a3050]
mov byte [eax + 0x5a3060], 0
jmp 0x40692c
push 0x200
push 0x5a6480
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push 0x4a11ec
push 0x5a6480
call fcn.0041bfb0
add esp, 8
push 0x5a98c0
push 0x5a3060
push 0x5a6480
call fcn.00409b53
add esp, 0xc
cmp eax, 0xffffffff
jne 0x40699f
mov eax, 0xffffffff
jmp 0x406bbd
mov ax, word [0x5a98c0]
mov word [ebp - 0x30], ax
push 0x5a6686
mov ax, word [0x5a98c0]
push eax
push 0x5a3060
push 0x4a11f8
call fcn.00407518
add esp, 0x10
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x4069db
mov dword [ebp - 0x34], 1
push 0x5a6686
mov ax, word [0x5a98c0]
push eax
push 0x5a3060
push 0x4a1208
call fcn.00407518
add esp, 0x10
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x406b9b
or dword [ebp - 8], 1
push 0x5a6686
mov ax, word [0x5a98c0]
push eax
push 0x5a3060
push 0x4a1214
call fcn.00407518
add esp, 0x10
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x406a3e
or dword [ebp - 8], 2
jmp 0x406b96
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0xc], eax
inc dword [ebp - 0x20]
push 0x4a121c
call fcn.0041bdf0
add esp, 4
push eax
push 0x4a1224
mov eax, dword [ebp - 0x20]
push eax
call fcn.0041c9f0
add esp, 0xc
test eax, eax
jne 0x406a44
push 0x4a122c
call fcn.0041bdf0
add esp, 4
inc eax
add dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x20]
mov al, byte [eax]
mov ecx, dword [ebp - 0x1c]
mov byte [ebp + ecx - 0x18], al
inc dword [ebp - 0x20]
inc dword [ebp - 0x1c]
mov eax, dword [ebp - 0x20]
xor ecx, ecx
mov cl, byte [eax]
cmp ecx, 0xd
jne 0x406a86
mov eax, dword [ebp - 0x1c]
mov byte [ebp + eax - 0x18], 0
lea eax, [ebp - 0x18]
push eax
push 0x5a98d0
call fcn.0041bfa0
add esp, 8
push 0x4a1234
lea eax, [ebp - 0x18]
push eax
call fcn.0041c3a0
add esp, 8
test eax, eax
jge 0x406aed
cmp dword [ebp - 0x34], 1
jne 0x406ae8
or dword [ebp - 8], 2
jmp 0x406b96
push 0x4a123c
lea eax, [ebp - 0x18]
push eax
call fcn.0041c3a0
add esp, 8
test eax, eax
jg 0x406b0f
or dword [ebp - 8], 2
jmp 0x406b96
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x20], eax
inc dword [ebp - 0x20]
push 0x4a1244
call fcn.0041bdf0
add esp, 4
push eax
push 0x4a124c
mov eax, dword [ebp - 0x20]
push eax
call fcn.0041c9f0
add esp, 0xc
test eax, eax
jne 0x406b15
push 0x4a1254
call fcn.0041bdf0
add esp, 4
inc eax
add dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x20]
mov al, byte [eax]
mov ecx, dword [ebp - 0x1c]
mov byte [ebp + ecx - 0x2c], al
inc dword [ebp - 0x20]
inc dword [ebp - 0x1c]
mov eax, dword [ebp - 0x20]
xor ecx, ecx
mov cl, byte [eax]
cmp ecx, 0xd
jne 0x406b57
lea eax, [ebp - 0x2c]
push eax
call fcn.0041c9e0
add esp, 4
mov dword [ebp - 4], eax
test byte [ebp - 4], 2
je 0x406b96
or dword [ebp - 8], 2
jmp 0x406bb5
cmp dword [ebp - 0x34], 1
jne 0x406bae
or dword [ebp - 8], 2
jmp 0x406bb5
mov dword [ebp - 8], 0
mov eax, dword [ebp - 8]
jmp 0x406bbd
pop edi
pop esi
pop ebx
leave
ret