Function at 0x41f6b0
Capabilities:
Check if file exists
Get file attributes
Set current directory

Disassembly:
sub esp, 0xb1c
push ebx
push ebp
mov ebp, dword [esp + 0xb28]
push esi
push edi
push 0x800
lea ecx, [esp + 0x1c]
push ecx
push 0
mov byte [ebp + 0x61e], al
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov dword [esp + 0x14], eax
test eax, eax
je 0x41f732
cmp eax, 0x800
jne 0x41f6f7
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xb1c
ret 8
mov ecx, eax
lea ebx, [esp + 0x18]
call fcn.0047c2d0
mov dword [ebp + 0x60c], eax
test eax, eax
je 0x41f6e8
mov edx, ebx
push 0x5c
push edx
call fcn.0049349c
add esp, 8
test eax, eax
je 0x41f732
mov ecx, eax
mov eax, ebx
sub ecx, eax
call fcn.0047c2d0
mov dword [ebp + 0x610], eax
test eax, eax
je 0x41f6e8
mov edi, dword [esp + 0xb34]
test edi, edi
jne 0x41f856
lea ecx, [esp + 0x18]
push 0x5c
push ecx
call fcn.0049349c
mov esi, eax
add esp, 8
test esi, esi
je 0x41f6e8
push 0x2e
push esi
call fcn.0049349c
add esp, 8
test eax, eax
je 0x41f6e8
mov edx, eax
lea ecx, [esp + 0x18]
sub edx, ecx
add edx, 5
cmp edx, 0x800
jae 0x41f6e8
mov edx, dword [str..ahk]
mov ebx, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov dword [eax], edx
mov cl, byte [0x4ab7a0]
lea edx, [esp + 0x18]
mov byte [eax + 4], cl
mov eax, edx
push eax
mov dword [esp + 0xb38], edx
call ebx
cmp eax, 0xffffffff
jne 0x41f84f
lea ecx, [esp + 0x920]
mov edx, ecx
push 0x4a7935
push edx
mov dword [esp + 0xb3c], ecx
call fcn.0044f8f0
mov ecx, esi
add esp, 8
lea edi, [ecx + 1]
nop
mov dl, byte [ecx]
inc ecx
test dl, dl
jne 0x41f7d0
sub ecx, edi
lea ecx, [ecx + eax + 1]
cmp ecx, 0x201
ja 0x41f6e8
lea edx, [esp + eax + 0x920]
mov ecx, esi
sub edx, esi
mov al, byte [ecx]
mov byte [edx + ecx], al
inc ecx
test al, al
jne 0x41f7f4
lea edx, [esp + 0x920]
push edx
call ebx
cmp eax, 0xffffffff
jne 0x41f84f
mov eax, dword [ebp + 0x610]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
push str.AutoHotkey.chm
call ebx
cmp eax, 0xffffffff
je 0x41f84f
push 0
push 0
push 0
push 0
push 0x4ab7b4
push 0
push 0
push str._ms_its:AutoHotkey.chm::_docs_Welcome.htm_
push ebp
mov edx, str.hh.exe
call fcn.0043c0c0
test eax, eax
jne 0x41f6e8
mov edi, dword [esp + 0xb34]
cmp byte [edi], 0x2a
mov esi, 2
jne 0x41f89c
cmp byte [edi + 1], 0
jne 0x41f889
mov dword [ebp + 0x618], esi
mov word [esp + 0x18], 0x2a
mov dword [0x4bb580], 4
mov dword [0x4bb594], 1
jmp 0x41f8a6
mov dword [ebp + 0x618], 1
mov byte [0x4b7492], 0
jmp 0x41f8a6
mov dword [ebp + 0x618], 0
lea ecx, [esp + 0x18]
cmp edi, ecx
je 0x41f8df
cmp dword [ebp + 0x618], 1
je 0x41f8df
push 0
mov edx, ecx
push edx
push 0x800
push edi
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
mov dword [esp + 0x14], eax
test eax, eax
je 0x41f6e8
cmp eax, 0x800
jae 0x41f6e8
cmp dword [ebp + 0x618], esi
je 0x41f91f
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x1c]
push 0x104
push ecx
lea ebx, [esp + 0x824]
call fcn.004800c0
add esp, 0xc
test eax, eax
je 0x41f91f
mov edx, dword [esp + 0x14]
inc edx
push edx
mov eax, ebx
push eax
lea ecx, [esp + 0x20]
push ecx
call fcn.0049b100
add esp, 0xc
cmp byte [esp + 0x18], 0
je 0x41f986
lea eax, [esp + 0x18]
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x41f930
sub eax, edx
mov edi, eax
lea eax, [edi + 1]
call fcn.0047c340
mov esi, eax
test esi, esi
jne 0x41f966
lea edx, [esp + 0x18]
push edx
push str.Out_of_memory.
mov ecx, 0x4bc450
call fcn.0043b430
mov edi, dword [esp + 0xb34]
jmp 0x41f98b
test edi, edi
je 0x41f979
push edi
lea eax, [esp + 0x1c]
push eax
push esi
call fcn.0049b100
add esp, 0xc
mov byte [esi + edi], 0
mov edi, dword [esp + 0xb34]
jmp 0x41f98b
mov esi, 0x4a7935
mov dword [ebp + 0x600], esi
test esi, esi
je 0x41f6e8
lea ecx, [esp + 0x18]
push 0x5c
push ecx
call fcn.0049349c
mov esi, eax
add esp, 8
test esi, esi
je 0x41f9ce
lea edx, [esp + 0x18]
mov ecx, esi
sub ecx, edx
mov ebx, edx
call fcn.0047c2d0
mov dword [ebp + 0x604], eax
test eax, eax
je 0x41f6e8
inc esi
jmp 0x41f9d2
lea esi, [esp + 0x18]
or ecx, 0xffffffff
mov ebx, esi
call fcn.0047c2d0
mov dword [ebp + 0x608], eax
test eax, eax
je 0x41f6e8
push 0x4a7954
push edi
call fcn.00492892
add esp, 8
test eax, eax
je 0x41fa23
cmp dword [ebp + 0x618], 1
mov eax, str.AutoHotkey_v1.1.34.03
jne 0x41fa0c
mov eax, edi
push eax
push str.____s
mov eax, 0x800
lea ecx, [esp + 0x20]
call fcn.0047f380
add esp, 8
or ecx, 0xffffffff
lea ebx, [esp + 0x18]
call fcn.0047c2d0
xor ecx, ecx
test eax, eax
setne cl
pop edi
pop esi
mov dword [ebp + 0x614], eax
pop ebp
pop ebx
mov eax, ecx
add esp, 0xb1c
ret 8