Function at 0x403f40
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
mov eax, dword [ebp + 8]
sub esp, 0x134
push ebx
push esi
push edi
push 0x4ad140
mov dword [0x4ae24c], eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push 1
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
lea ecx, [esp + 0x38]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
test eax, eax
je 0x403f87
lea eax, [esp + 0x38]
call fcn.00450460
mov eax, dword [0x4abaac]
test eax, eax
je 0x403fe0
mov ebx, dword [eax]
test ebx, ebx
je 0x403fe0
cmp byte [ebx], 0
je 0x403fe0
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403fa0
sub eax, edx
mov edi, eax
lea eax, [edi + 1]
call fcn.00471d90
mov esi, eax
test esi, esi
jne 0x403fcb
push ebx
push str.Out_of_memory.
mov ecx, 0x4af210
call fcn.0042fe10
jmp 0x403fe5
test edi, edi
je 0x403fda
push edi
push ebx
push esi
call fcn.00490240
add esp, 0xc
mov byte [esi + edi], 0
jmp 0x403fe5
mov esi, 0x49b8bd
mov eax, dword [0x4ac104]
mov edi, 1
mov dword [0x4aea64], esi
mov byte [esp + 0x2c], 0
cmp eax, edi
jle 0x4040b7
mov bl, 0x3d
jmp 0x404010
mov edx, dword [0x4ac108]
mov esi, dword [edx + edi*4]
push 0x49b8dc
push esi
call fcn.00487c11
add esp, 8
test eax, eax
je 0x40409d
push str._restart
push esi
call fcn.00487c11
add esp, 8
test eax, eax
je 0x40409d
push 0x49b8ec
push esi
call fcn.00487c11
add esp, 8
test eax, eax
je 0x404094
push str._force
push esi
call fcn.00487c11
add esp, 8
test eax, eax
je 0x404094
push 0xc
push str._ErrorStdOut
push esi
call fcn.00487fcd
add esp, 0xc
test eax, eax
jne 0x4040b2
cmp byte [esi + 0xc], bl
jne 0x40407f
lea eax, [esi + 0xd]
jmp 0x404081
xor eax, eax
mov byte [0x4af82f], 1
call fcn.00416610
mov dword [0x4af830], eax
jmp 0x4040a2
mov byte [0x4ae277], 1
jmp 0x4040a2
mov byte [esp + 0x2c], 1
mov eax, dword [0x4ac104]
inc edi
cmp edi, eax
jl 0x404010
jmp 0x4040b7
mov eax, dword [0x4ac104]
sub eax, edi
push eax
mov eax, dword [0x4ac108]
lea ecx, [eax + edi*4]
push ecx
call fcn.004044d0
add esp, 8
test eax, eax
je 0x4043d5
lea edx, [esp + 0x2b]
push edx
push 0xc1
lea eax, [esp + 0x38]
push eax
push 6
push str.A_Args
mov ecx, 0x4af210
call fcn.00422fa0
test eax, eax
jne 0x40411f
mov edx, dword [esp + 0x30]
xor ecx, ecx
cmp byte [esp + 0x2b], cl
setne cl
inc ecx
or ecx, 0xc0
push ecx
push edx
push 0x4af210
lea ecx, [eax + 6]
mov edx, str.A_Args
call fcn.00423240
mov esi, eax
test esi, esi
je 0x4043d5
mov eax, dword [0x4ac108]
mov ebx, dword [0x4ac104]
lea ecx, [eax + edi*4]
sub ebx, edi
push ecx
call fcn.0046e0b0
add esp, 4
test eax, eax
je 0x4043d5
mov edi, eax
mov ecx, esi
call fcn.00477cc0
call fcn.00403dc0
mov edx, dword [esp + 0x2c]
push edx
push 0x4af210
call fcn.00416fa0
cmp eax, 1
jne 0x4043d5
mov esi, dword [0x4aa978]
mov ecx, 0x3a
mov edi, 0x4acf10
mov eax, 0x4af210
rep movsd dword es:[edi], dword [esi]
call fcn.00417d20
cmp eax, 0xffffffff
je 0x4043d5
test eax, eax
jne 0x4041a4
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov eax, dword [0x4ae3ac]
test eax, eax
jne 0x4041ec
mov eax, dword [0x4abab4]
cmp word [eax], 0
jne 0x4041e0
cmp dword [0x4aeacc], 0
jne 0x4041e0
cmp dword [0x4ae384], 0
jne 0x4041e0
cmp dword [0x4ae388], 0
jne 0x4041e0
cmp byte [0x4ae391], 0
je 0x404264
mov dword [0x4ae3ac], 1
jmp 0x4041f1
cmp eax, 4
je 0x404264
cmp byte [esp + 0x2c], 0
jne 0x40426f
cmp byte [0x4ae277], 0
jne 0x4042ef
mov ecx, dword [0x4af824]
push ecx
push str.AutoHotkey
call dword [sym.imp.USER32.dll_FindWindowA]
mov edi, eax
test edi, edi
je 0x4042ef
mov eax, dword [0x4ae3ac]
cmp eax, 3
je 0x404199
cmp eax, 2
je 0x40425d
fldz
mov edx, dword [0x4af818]
sub esp, 8
fstp qword [esp]
push 0
push edx
push 4
push str.An_older_instance_of_this_script_is_already_running.__Replace_it_with_this_instance__nNote:_To_avoid_this_message__see_SingleInstance_in_the_help_file.
call fcn.004795b0
add esp, 0x18
cmp eax, 7
je 0x404199
mov eax, 0x407
jmp 0x40428b
cmp byte [esp + 0x2c], 0
je 0x4042ef
mov eax, dword [0x4af824]
push eax
push str.AutoHotkey
call dword [sym.imp.USER32.dll_FindWindowA]
mov edi, eax
test edi, edi
je 0x4042ef
mov eax, 0x406
push 0
push eax
push 0x44
push edi
call dword [sym.imp.USER32.dll_PostMessageA]
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x14
xor esi, esi
call ebx
push edi
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x4042eb
mov edi, edi
cmp esi, 0x64
jne 0x4042db
fldz
sub esp, 8
fstp qword [esp]
push 0
push 0
push 4
push str.Could_not_close_the_previous_instance_of_this_script.__Keep_waiting_
call fcn.004795b0
add esp, 0x18
cmp eax, 7
je 0x4043d5
xor esi, esi
push 0x14
inc esi
call ebx
push edi
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
jne 0x4042b0
push 0x64
call ebx
mov esi, dword [sym.imp.USER32.dll_SystemParametersInfoA]
push 0
push 0x4ace24
push 0
push 0x2000
call esi
test eax, eax
je 0x40431f
cmp dword [0x4ace24], 0
je 0x40431f
push 2
push 0
push 0
push 0x2001
call esi
push 0x4af210
call fcn.004171c0
cmp eax, 1
jne 0x4043d5
push 0
push 4
push 0
call fcn.0048845c
add eax, 0x20
push eax
call fcn.00488366
mov esi, dword [0x4aa8f0]
add esp, 0x10
test esi, esi
je 0x404374
imul esi, esi, 0x70
push esi
call fcn.00487fe7
add esp, 4
mov dword [0x4aea6c], eax
test eax, eax
je 0x404374
push esi
push 0
push eax
call fcn.00490e10
add esp, 0xc
cmp byte [0x4af9d2], 0
jne 0x404398
lea ecx, [esp + 0x30]
push ecx
mov dword [esp + 0x34], 8
mov dword [esp + 0x38], 0x1ff
call dword [sym.imp.COMCTL32.dll_InitCommonControlsEx]
call fcn.0040a2a0
push 3
push 0
push str.Clipboard
mov ecx, 0x4af210
mov byte [0x4af82c], 1
mov byte [0x4aea5a], 0
call fcn.00422f40
test eax, eax
je 0x4043c7
call fcn.00403f10
call fcn.004043f0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
pop edi
pop esi
mov eax, 2
pop ebx
mov esp, ebp
pop ebp
ret 0x10