Function at 0x409664
Capabilities:
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
lea eax, [ebp + 8]
push ebx
push esi
push edi
test eax, eax
jne 0x40989b
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov esi, dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea eax, [ebp - 0xc]
push eax
push 3
pop ebx
push ebx
call esi
test eax, eax
je 0x4096a7
cmp byte [ebp - 0xb], 0x3a
jne 0x4096a7
movzx eax, byte [ebp - 0xc]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x4096c3
cmp byte [ebp - 3], 0x3a
jne 0x4096c3
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x4096df
cmp byte [ebp - 3], 0x3a
jne 0x4096df
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
mov edi, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea eax, [ebp - 4]
push eax
call edi
test eax, eax
je 0x409700
cmp byte [ebp - 3], 0x3a
jne 0x409700
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp + 8]
cmp eax, 0x37
jne 0x409773
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x409724
cmp byte [ebp - 3], 0x3a
jne 0x409724
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x409740
cmp byte [ebp - 3], 0x3a
jne 0x409740
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x40975c
cmp byte [ebp - 3], 0x3a
jne 0x40975c
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
and byte [ebp - 6], 0
lea eax, [ebp - 8]
push eax
mov byte [ebp - 8], 0x42
mov byte [ebp - 7], 0x3a
call edi
jmp 0x409831
lea eax, [ebp - 8]
push eax
push ebx
call esi
test eax, eax
je 0x40978f
cmp byte [ebp - 7], 0x3a
jne 0x40978f
movzx eax, byte [ebp - 8]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 8]
push eax
call edi
test eax, eax
je 0x4097aa
cmp byte [ebp - 7], 0x3a
jne 0x4097aa
movzx eax, byte [ebp - 8]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp + 8]
cmp eax, 0x37
jne 0x4097e2
lea eax, [ebp - 8]
push eax
push ebx
call esi
test eax, eax
je 0x4097ce
cmp byte [ebp - 7], 0x3a
jne 0x4097ce
movzx eax, byte [ebp - 8]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
and byte [ebp - 0xe], 0
lea eax, [ebp - 0x10]
push eax
mov byte [ebp - 0x10], 0x42
mov byte [ebp - 0xf], 0x3a
call edi
jmp 0x409806
push 0
call dword [sym.imp.KERNEL32.dll_PulseEvent]
lea eax, [ebp - 8]
push eax
push ebx
call esi
test eax, eax
je 0x409806
cmp byte [ebp - 7], 0x3a
jne 0x409806
movzx eax, byte [ebp - 8]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp - 4]
push eax
push ebx
call esi
test eax, eax
je 0x409822
cmp byte [ebp - 3], 0x3a
jne 0x409822
movzx eax, byte [ebp - 4]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
push 0
push 1
push 0xc8d
call dword [sym.imp.KERNEL32.dll_OpenEventA]
lea eax, [ebp - 0xc]
push eax
call edi
test eax, eax
je 0x40984c
cmp byte [ebp - 0xb], 0x3a
jne 0x40984c
movzx eax, byte [ebp - 0xc]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
lea eax, [ebp + 8]
cmp eax, 0x37
lea eax, [ebp - 0xc]
push eax
push ebx
jne 0x409884
call esi
test eax, eax
je 0x409870
cmp byte [ebp - 0xb], 0x3a
jne 0x409870
movzx eax, byte [ebp - 0xc]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
and byte [ebp - 0xe], 0
lea eax, [ebp - 0x10]
push eax
mov byte [ebp - 0x10], 0x42
mov byte [ebp - 0xf], 0x3a
call edi
jmp 0x40989b
call esi
test eax, eax
je 0x40989b
cmp byte [ebp - 0xb], 0x3a
jne 0x40989b
movzx eax, byte [ebp - 0xc]
push eax
call sub.MSVCRT.dll_toupper
pop ecx
push dword [ebp + 8]
lea eax, [ebp - 0x114]
push eax
mov eax, dword [0x4293d0]
call dword [eax + 0x1e8]
mov eax, dword [0x4293d0]
pop ecx
pop ecx
push 1
push 0
lea ecx, [ebp - 0x114]
push 0x5c
push ecx
lea esi, [eax + 0x21c]
call dword [eax + 0x1ec]
pop ecx
pop ecx
push eax
call dword [esi]
lea eax, [ebp - 0x114]
push 0x5c
push eax
mov eax, dword [0x4293d0]
call dword [eax + 0x1ec]
add esp, 0x14
test eax, eax
pop edi
pop esi
pop ebx
je 0x409908
inc eax
push eax
mov eax, dword [0x4293d0]
push dword [ebp + 0xc]
call dword [eax + 0x1e8]
pop ecx
pop ecx
push 1
pop eax
leave
ret 8