Function at 0x4c32e40
Capabilities:
Get common file path

Disassembly:
sub esp, 0x1a8
push ebp
push esi
push edi
mov byte [esp + 0x18], 0
call fcn.04c323a0
mov esi, dword [esp + 0x1b8]
mov ebp, eax
test ebp, ebp
je 0x4c32eac
mov eax, dword [ebp + 0x34]
test eax, eax
je 0x4c32eac
lea ecx, [esp + 0xc]
push ecx
lea edx, [esp + 0x14]
push edx
push eax
lea eax, [esp + 0x24]
push 0x104
push eax
call fcn.04c38d60
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
push 0
push 0
push esi
push ecx
push edx
call fcn.04c38df0
lea eax, [esp + 0x40]
push 4
push eax
call fcn.04c37430
add esp, 0x30
test eax, eax
je 0x4c3327e
mov byte [esp + 0x18], 0
call fcn.04c323a0
test eax, eax
je 0x4c32f19
mov edx, dword [eax]
push 0x104
lea ecx, [esp + 0x1c]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x18]
push eax
call fcn.04c37e10
lea eax, [esp + 0x1c]
add esp, 4
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4c32ee1
sub eax, edx
test eax, eax
jle 0x4c32f19
push 0
push 0
push esi
lea ecx, [esp + 0x24]
push 0x104
push ecx
call fcn.04c38df0
lea edx, [esp + 0x2c]
push 4
push edx
call fcn.04c37430
add esp, 0x1c
test eax, eax
je 0x4c3327e
push 0
push 0
push esi
lea eax, [esp + 0x24]
push 0x104
push eax
call fcn.04c38d60
lea ecx, [esp + 0x2c]
push 4
push ecx
call fcn.04c37430
add esp, 0x1c
test eax, eax
je 0x4c3327e
mov eax, esi
call fcn.04c32d40
mov edi, eax
mov eax, dword [ebp + 0x38]
test eax, eax
je 0x4c32fe8
push 0x96
lea edx, [esp + 0x120]
push edx
push str.SYBASE
call fcn.04c38d10
add esp, 0xc
test eax, eax
je 0x4c32fe8
push 0
push 0
push eax
lea eax, [esp + 0x24]
push 0x104
push eax
call fcn.04c38d60
lea ecx, [esp + 0x2c]
push 0
push ecx
call fcn.04c37d20
push 0
push 0
push 0x4c6c49c
lea edx, [esp + 0x40]
push 0x104
push edx
call fcn.04c38df0
lea eax, [esp + 0x48]
push 0
push eax
call fcn.04c37d20
push 0
push 0
push esi
lea ecx, [esp + 0x5c]
push 0x104
push ecx
call fcn.04c38df0
add esp, 0x4c
lea edx, [esp + 0x18]
push 4
push edx
call fcn.04c37430
add esp, 8
test eax, eax
je 0x4c3327e
mov eax, str.win32_
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4c32ff0
sub eax, edx
mov dword [esp + 0x14], eax
je 0x4c33099
push edi
push str.win32_
call fcn.04c59caa
add esp, 8
test eax, eax
je 0x4c33099
lea eax, [esp + 0x18]
push 0x104
push eax
call fcn.04c32cf0
add esp, 8
test eax, eax
jle 0x4c33099
lea edx, [esp + 0xc]
push edx
lea edx, [esp + 0x14]
push edx
mov ecx, 0x104
sub ecx, eax
push 0x4c6c498
push ecx
lea eax, [esp + eax + 0x28]
push eax
mov dword [esp + 0x20], ecx
call fcn.04c38df0
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x28]
push edx
push edi
push eax
push ecx
call fcn.04c38df0
mov edx, dword [esp + 0x34]
mov eax, dword [esp + 0x38]
push 0
push 0
push esi
push edx
push eax
call fcn.04c38df0
lea ecx, [esp + 0x54]
push 4
push ecx
call fcn.04c37430
add esp, 0x44
test eax, eax
je 0x4c3327e
push 0x104
lea edx, [esp + 0x1c]
push edx
push str.Location
push 0x4c6c418
mov byte [esp + 0x28], 0
call fcn.04c38cf0
add esp, 0x10
test eax, eax
je 0x4c3310f
lea eax, [esp + 0x18]
push 0
push eax
call fcn.04c37d20
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x1c]
push edx
push edi
lea eax, [esp + 0x2c]
push 0x104
push eax
call fcn.04c38df0
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
push 0
push 0
push esi
push ecx
push edx
call fcn.04c38df0
lea eax, [esp + 0x48]
push 4
push eax
call fcn.04c37430
add esp, 0x38
test eax, eax
je 0x4c3327e
push 0x104
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea edx, [esp + 0x18]
push 0
push edx
call fcn.04c37d20
push 0
push 0
push esi
lea eax, [esp + 0x2c]
push 0x104
push eax
call fcn.04c38df0
lea ecx, [esp + 0x34]
push 4
push ecx
call fcn.04c37430
add esp, 0x24
test eax, eax
je 0x4c3327e
push 0x104
lea edx, [esp + 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [esp + 0x18]
push 0
push eax
call fcn.04c37d20
push 0
push 0
push esi
lea ecx, [esp + 0x2c]
push 0x104
push ecx
call fcn.04c38df0
lea edx, [esp + 0x34]
push 4
push edx
call fcn.04c37430
add esp, 0x24
test eax, eax
je 0x4c3327e
lea eax, [esp + 0x18]
push eax
push str.PATH
push esi
call fcn.04c5b08b
mov al, byte [esp + 0x24]
add esp, 0xc
test al, al
jne 0x4c3327e
push 0x96
lea ecx, [esp + 0x120]
push ecx
push str.ASDIR
call fcn.04c38d10
add esp, 0xc
test eax, eax
jne 0x4c3321a
push 0x96
lea edx, [esp + 0x120]
push edx
push str.ASANY8
call fcn.04c38d10
add esp, 0xc
test eax, eax
jne 0x4c3321a
push 0x96
lea eax, [esp + 0x120]
push eax
push str.ASANY
call fcn.04c38d10
add esp, 0xc
test eax, eax
je 0x4c332c4
push 0
push 0
push eax
lea ecx, [esp + 0x24]
push 0x104
push ecx
call fcn.04c38d60
lea edx, [esp + 0x2c]
push 0
push edx
call fcn.04c37d20
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x30]
push ecx
push edi
lea edx, [esp + 0x40]
push 0x104
push edx
call fcn.04c38df0
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x40]
push 0
push 0
push esi
push eax
push ecx
call fcn.04c38df0
add esp, 0x44
lea edx, [esp + 0x18]
push 4
push edx
call fcn.04c37430
add esp, 8
test eax, eax
jne 0x4c332c4
lea eax, [esp + 0x18]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4c33285
sub eax, edx
mov esi, eax
mov eax, dword [esp + 0x1c0]
lea ecx, [esi + 1]
cmp ecx, eax
jg 0x4c332b8
push 0
push 0
lea edx, [esp + 0x20]
push edx
push eax
mov eax, dword [esp + 0x1cc]
push eax
call fcn.04c38d60
add esp, 0x14
pop edi
mov eax, esi
pop esi
pop ebp
add esp, 0x1a8
ret
mov ecx, dword [esp + 0x1bc]
pop edi
pop esi
mov byte [ecx], 0
xor eax, eax
pop ebp
add esp, 0x1a8
ret