Function at 0x4afb8c
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffdc0
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x23c], ecx
mov dword [ebp - 0x240], ecx
mov dword [ebp - 0x238], ecx
mov dword [ebp - 0x234], ecx
mov dword [ebp - 0x230], ecx
mov dword [ebp - 0x22c], ecx
mov dword [ebp - 0x228], ecx
mov dword [ebp - 4], ecx
mov dword [ebp - 8], ecx
mov dword [ebp - 0x10], edx
mov dword [ebp - 0xc], eax
xor eax, eax
push ebp
push 0x4afe25
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 0x11], 0
push 0x104
lea eax, [ebp - 0x222]
push eax
call sub.kernel32.dll_GetSystemDirectoryW
lea eax, [ebp - 0x228]
lea edx, [ebp - 0x222]
mov ecx, 0x105
call sub.rtl120.bpl__System__UStrFromWArray_qqrr20System_UnicodeStringpbi
mov edx, dword [ebp - 0x228]
lea eax, [ebp - 4]
mov ecx, 0x4afe44
call sub.rtl120.bpl__System__UStrCat3_qqrr20System_UnicodeStringx20System_UnicodeStringt2
mov dl, 1
mov eax, dword [sym.imp.rtl120.bpl__Classes_TStringList_]
call sub.rtl120.bpl__Classes_TStringList__bctr_qqrv
mov dword [ebp - 0x18], eax
xor eax, eax
push ebp
push 0x4afdf3
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
call sub.rtl120.bpl__Sysutils_FileExists_qqrx20System_UnicodeString
test al, al
je 0x4afdd4
xor eax, eax
push ebp
push 0x4afd63
push dword fs:[eax]
mov dword fs:[eax], esp
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
call dword [ecx + 0x68]
mov eax, dword [ebp - 0x18]
mov edx, dword [eax]
call dword [edx + 0x14]
mov ebx, eax
dec ebx
test ebx, ebx
jl 0x4afd59
inc ebx
xor esi, esi
lea ecx, [ebp - 8]
mov edx, esi
mov eax, dword [ebp - 0x18]
mov edi, dword [eax]
call dword [edi + 0xc]
lea edx, [ebp - 0x22c]
mov eax, dword [ebp - 8]
call sub.rtl120.bpl__Sysutils_Trim_qqrx20System_UnicodeString
mov edx, dword [ebp - 0x22c]
lea eax, [ebp - 8]
call sub.rtl120.bpl__System__UStrLAsg_qqrr20System_UnicodeStringx20System_UnicodeString
mov eax, dword [ebp - 8]
call sub.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
call sub.rtl120.bpl__Sysutils_StrLower_qqrpb
mov edx, eax
lea eax, [ebp - 8]
call sub.rtl120.bpl__System__UStrFromPWChar_qqrr20System_UnicodeStringpb
mov edx, dword [ebp - 8]
mov eax, 0x4afe78
call sub.rtl120.bpl__System_Pos_qqrx20System_UnicodeStringt1
test eax, eax
jg 0x4afcfc
mov edx, dword [ebp - 8]
mov eax, 0x4afe98
call sub.rtl120.bpl__System_Pos_qqrx20System_UnicodeStringt1
test eax, eax
jg 0x4afcfc
mov edx, dword [ebp - 8]
mov eax, 0x4afeb8
call sub.rtl120.bpl__System_Pos_qqrx20System_UnicodeStringt1
test eax, eax
jg 0x4afcfc
mov edx, dword [ebp - 8]
mov eax, 0x4afef0
call sub.rtl120.bpl__System_Pos_qqrx20System_UnicodeStringt1
test eax, eax
jle 0x4afd51
mov edx, dword [ebp - 8]
mov eax, 0x4aff18
call sub.rtl120.bpl__System_Pos_qqrx20System_UnicodeStringt1
dec eax
je 0x4afd51
mov byte [ebp - 0x11], 1
lea ecx, [ebp - 0x230]
mov edx, esi
mov eax, dword [ebp - 0x18]
mov edi, dword [eax]
call dword [edi + 0xc]
cmp dword [ebp - 0x230], 0
je 0x4afd51
mov eax, dword [ebp - 0xc]
cmp dword [eax], 0
je 0x4afd51
lea ecx, [ebp - 0x234]
mov edx, esi
mov eax, dword [ebp - 0x18]
mov edi, dword [eax]
call dword [edi + 0xc]
mov edx, dword [ebp - 0x234]
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov ecx, dword [eax]
call dword [ecx + 0x38]
inc esi
dec ebx
jne 0x4afc78
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4afddd
mov eax, dword [ebp - 0x10]
mov dword [eax], 2
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4afdfa
mov eax, dword [ebp - 0x18]
call sub.rtl120.bpl__System_TObject_Free_qqrv
ret