Function at 0x4041f7
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x40c830
push 0x40bc72
mov eax, dword fs:[0]
push eax
push ecx
push ecx
mov eax, 0x105c
call fcn.0040c560
mov eax, dword [0x40d004]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x20], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0xf6c], eax
xor ebx, ebx
mov dword [ebp - 0xf80], ebx
mov byte [ebp - 0x12c], bl
push 0x103
push ebx
lea eax, [ebp - 0x12b]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0x334], ax
mov esi, 0x206
push esi
push ebx
lea eax, [ebp - 0x332]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0x53c], ax
push esi
push ebx
lea eax, [ebp - 0x53a]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0x744], ax
push esi
push ebx
lea eax, [ebp - 0x742]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0x94c], ax
push esi
push ebx
lea eax, [ebp - 0x94a]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0xb54], ax
push esi
push ebx
lea eax, [ebp - 0xb52]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0xf64], ax
push esi
push ebx
lea eax, [ebp - 0xf62]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
xor eax, eax
mov word [ebp - 0xd5c], ax
push esi
push ebx
lea eax, [ebp - 0xd5a]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
lea eax, [ebp - 0xd5c]
mov dword [ebp - 0xf7c], eax
mov dword [ebp - 0xf68], 0x40171c
mov esi, 0x4016cc
call fcn.00405dc3
test eax, eax
jne 0x404347
xor eax, eax
jmp 0x404970
call fcn.00403afe
test eax, eax
je 0x40435f
mov esi, 0x4016ec
mov dword [ebp - 0xf68], 0x401730
push 1
push esi
call dword [0x40fad4]
mov edi, eax
mov dword [ebp - 0xf74], edi
test edi, edi
jne 0x4043a2
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x40439e
mov dword [ebp - 0xf68], 0x40171c
push 1
push 0x4016cc
call dword [0x40fad4]
mov edi, eax
mov dword [ebp - 0xf74], edi
test edi, edi
je 0x404340
inc dword [0x40faac]
xor eax, eax
mov esi, dword [0x40fab4]
test esi, esi
setne al
mov dword [ebp - 0xf78], eax
test eax, eax
je 0x40498e
mov dword [ebp - 0xf68], esi
mov dword [ebp - 0xf70], ebx
mov eax, dword [ebp - 0xf6c]
test eax, eax
je 0x4043f7
push eax
push 0x401798
push 0x104
lea eax, [ebp - 0x12c]
push eax
call fcn.004039aa
add esp, 0x10
test eax, eax
jns 0x404422
push 0xfa
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jne 0x404422
push 0x40179c
mov edx, 0x104
lea ecx, [ebp - 0x12c]
call fcn.0040385f
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x334]
mov dword [ebp - 0xff4], eax
mov dword [ebp - 0xff0], ebx
mov dword [ebp - 0xfec], ebx
mov dword [ebp - 0xfe8], ebx
lea eax, [ebp - 0x53c]
mov dword [ebp - 0x1024], eax
mov dword [ebp - 0x1020], ebx
mov dword [ebp - 0x101c], ebx
mov dword [ebp - 0x1018], ebx
lea eax, [ebp - 0x94c]
mov dword [ebp - 0x1044], eax
mov dword [ebp - 0x1040], ebx
mov dword [ebp - 0x103c], ebx
mov dword [ebp - 0x1038], ebx
lea eax, [ebp - 0x744]
mov dword [ebp - 0x105c], eax
mov dword [ebp - 0x1058], ebx
mov dword [ebp - 0x1054], ebx
mov dword [ebp - 0x1050], ebx
mov dword [ebp - 0x1074], 0x4017a0
mov dword [ebp - 0x1070], ebx
mov dword [ebp - 0x106c], ebx
mov dword [ebp - 0x1068], ebx
lea eax, [ebp - 0xb54]
mov dword [ebp - 0xfe4], eax
mov dword [ebp - 0xfe0], ebx
mov dword [ebp - 0xfdc], ebx
mov dword [ebp - 0xfd8], ebx
lea eax, [ebp - 0xf64]
mov dword [ebp - 0xfd4], eax
mov dword [ebp - 0xfd0], ebx
mov dword [ebp - 0xfcc], ebx
mov dword [ebp - 0xfc8], ebx
mov dword [ebp - 0xfa8], 0x401788
mov edx, 0x401750
mov dword [ebp - 0xfa4], edx
mov eax, 0x401758
mov dword [ebp - 0xfa0], eax
mov ecx, 0x401780
mov dword [ebp - 0xf9c], ecx
mov dword [ebp - 0xf98], 0x401790
mov dword [ebp - 0xf94], ebx
mov dword [ebp - 0xfc4], edx
mov dword [ebp - 0xfc0], eax
mov dword [ebp - 0xfbc], 0x401760
mov dword [ebp - 0xfb8], 0x401768
mov dword [ebp - 0xfb4], 0x401770
mov dword [ebp - 0xfb0], 0x401778
mov dword [ebp - 0xfac], ecx
mov dword [ebp - 0x1064], 0x4017b0
mov dword [ebp - 0x1060], 0x4017c8
mov dword [ebp - 0x104c], 0x401800
mov dword [ebp - 0x1048], 0x401818
mov dword [ebp - 0x1004], edx
mov eax, 0x4000000
mov dword [ebp - 0x1000], eax
xor ecx, ecx
inc ecx
mov dword [ebp - 0xffc], ecx
mov dword [ebp - 0xff8], ebx
mov dword [ebp - 0xf90], edx
mov dword [ebp - 0xf8c], 0x2000000
mov dword [ebp - 0xf88], ecx
mov dword [ebp - 0xf84], ebx
mov dword [ebp - 0x1014], edx
mov dword [ebp - 0x1010], 0x3000000
mov dword [ebp - 0x100c], ecx
mov dword [ebp - 0x1008], ecx
mov dword [ebp - 0x1034], edx
mov dword [ebp - 0x1030], eax
mov dword [ebp - 0x102c], ebx
mov dword [ebp - 0x1028], ebx
push 0x401848
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0x334]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x401870
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0x53c]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x40188c
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0x744]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x4018a8
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0xb54]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x4018c0
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0xf64]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x4018d8
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0x94c]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
push 0x4018ec
lea eax, [ebp - 0x12c]
push eax
push 0x401864
push 0x104
lea eax, [ebp - 0xd5c]
push eax
call fcn.004039f1
add esp, 0x14
test eax, eax
js 0x40495f
mov dword [0x40fab8], 1
test dword [0x40fab0], 0x1000000
jne 0x40476d
push 0x40413c
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov dword [0x40faa8], eax
or dword [0x40fab0], 0x1000000
call fcn.0040418e
test eax, eax
je 0x40495f
mov eax, dword [0x40fab0]
test eax, 0x1000
jne 0x4047c7
mov eax, dword [esi]
push ebx
lea ecx, [ebp - 0xff4]
push ecx
push 0x40199c
lea ecx, [ebp - 0xfa8]
push ecx
push 0x4019ec
lea ecx, [ebp - 0x1004]
push ecx
push 0x4019bc
push esi
call dword [eax]
test eax, eax
je 0x40495f
mov eax, dword [0x40fab0]
or eax, 0x1000
mov dword [0x40fab0], eax
test eax, 0x2000
jne 0x40480f
mov eax, dword [esi]
push ebx
lea ecx, [ebp - 0x1024]
push ecx
push 0x40199c
lea ecx, [ebp - 0xfa8]
push ecx
push 0x4019ec
lea ecx, [ebp - 0xf90]
push ecx
push 0x4019bc
push esi
call dword [eax]
test eax, eax
je 0x40495f
mov eax, dword [0x40fab0]
or eax, 0x2000
mov dword [0x40fab0], eax
mov dword [0x40fab0], eax
test eax, 0x8000
jne 0x40484c
mov eax, dword [esi]
push ebx
push ebx
push ebx
lea ecx, [ebp - 0xfc4]
push ecx
push 0x4019fc
push ecx
push 0x4019dc
push esi
call dword [eax]
test eax, eax
je 0x40495f
mov eax, dword [0x40fab0]
or eax, 0x8000
mov dword [0x40fab0], eax
test eax, 0x4000
jne 0x4048b5
mov eax, dword [esi]
push ebx
lea ecx, [ebp - 0xfe4]
push ecx
push 0x40199c
push ebx
push 0x4019cc
lea ecx, [ebp - 0xf90]
push ecx
push 0x4019bc
push esi
call dword [eax]
test eax, eax
je 0x40495f
mov eax, dword [esi]
push ebx
lea ecx, [ebp - 0xfd4]
push ecx
push 0x40199c
push ebx
push 0x4019cc
lea ecx, [ebp - 0x1014]
push ecx
push 0x4019bc
push esi
call dword [eax]
test eax, eax
je 0x40495f
or dword [0x40fab0], 0x4000
mov eax, dword [ebp - 0xf78]
test eax, eax
jne 0x4048f8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov dword [0x40fa98], eax
mov dword [0x40fab4], esi
push 0x104
push 0x40f2c8
push ebx
call dword [0x40fadc]
push 0x104
push str._unknown_
push ebx
call dword [0x40fad0]
mov eax, dword [ebp - 0xf78]
mov dword [ebp - 0xf70], 1
test eax, eax
jne 0x40495f
mov eax, dword [esi]
push ebx
lea ecx, [ebp - 0xf7c]
push ecx
push 0x4019ac
push esi
call dword [eax + 8]
test eax, eax
jne 0x40495f
mov eax, dword [ebp + 4]
mov dword [ebp - 0xf6c], eax
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp - 0xf6c]
push 0x4016cc
push ecx
push 0x595
push ebx
push ecx
push 0x401908
push 0x67000000
call fcn.004035b5
pop ecx
pop ecx
mov edx, 0x90000
mov ecx, eax
call fcn.00404c9f
mov dword [ebp - 4], 0xfffffffe
call fcn.004049da
mov eax, dword [0x40fab4]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x20]
xor ecx, ebp
call fcn.0040b8ba
mov esp, ebp
pop ebp
ret 4
call fcn.004065b4
push ecx
mov ecx, dword [ebp - 0xf68]
call fcn.0040809c
mov esi, eax
mov dword [ebp - 0xf68], esi
test esi, esi
jne 0x4043c9
dec dword [0x40faac]
push edi
call dword [0x40fabc]
push edi
call dword [0x40fac4]
jmp 0x404340