Function at 0x4f4d78
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffb4
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 8], ecx
mov esi, edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x4f4f5f
push dword fs:[eax]
mov dword fs:[eax], esp
cmp esi, 0xffffffff
jle 0x4f4f1b
mov eax, dword [ebp - 4]
call fcn.004f7374
cmp esi, eax
jge 0x4f4f1b
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x128]
mov edx, esi
call fcn.004d8cf4
mov edx, dword [0x4d9b68]
call sub.rtl250.bpl__System__AsClass_qqrxp14System_TObjectp17System_TMetaClass
mov edi, eax
mov eax, edi
call fcn.004dd128
test al, al
je 0x4f4f11
mov dword [ebp - 0x10], 0
mov dword [ebp - 0xc], 0
mov eax, dword [edi + 0x50]
call sub.rtl250.bpl__System__LStrLen_qqrx31System__AnsiStringT_us_i65535__
test eax, eax
jne 0x4f4f04
xor eax, eax
push ebp
push 0x4f4efd
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
call fcn.004f5f9c
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
call sub.rtl250.bpl__System_Classes_TStream_GetPosition_qqrv
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], edx
push dword [edi + 0x34]
push dword [edi + 0x30]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
xor edx, edx
mov ecx, dword [eax]
call dword [ecx + 0x28]
lea edx, [ebp - 0x3e]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
mov ecx, 0x2e
mov ebx, dword [eax]
call dword [ebx + 0xc]
movzx eax, word [ebp - 0x22]
movzx edx, word [ebp - 0x20]
add eax, edx
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
mov dl, 1
mov ecx, dword [eax]
call dword [ecx + 0x28]
movzx ebx, word [ebp - 0x1e]
mov eax, dword [ebp - 8]
xor ecx, ecx
mov edx, ebx
call sub.rtl250.bpl__System__LStrSetLength_qqrr27System__AnsiStringT_us_i0__ius
mov eax, dword [ebp - 8]
call sub.rtl250.bpl__System__UniqueStringA_qqrr27System__AnsiStringT_us_i0__
mov edx, eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
mov ecx, ebx
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x168]
movzx ebx, byte [eax + 0x28]
mov ecx, dword [ebp - 8]
mov ecx, dword [ecx]
mov edx, esi
mov eax, dword [ebp - 4]
call fcn.004f537c
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x168]
mov byte [eax + 0x28], bl
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4f4f49
push dword [ebp - 0xc]
push dword [ebp - 0x10]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x140]
xor edx, edx
mov ecx, dword [eax]
call dword [ecx + 0x28]
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x50]
test al, al
jne 0x4f4efc
mov eax, dword [ebp - 4]
call fcn.004f6024
ret
mov eax, dword [ebp - 8]
mov edx, dword [edi + 0x50]
call sub.rtl250.bpl__System__LStrAsg_qqrr27System__AnsiStringT_us_i0__x27System__AnsiStringT_us_i0__
jmp 0x4f4f49
mov eax, dword [ebp - 8]
call sub.rtl250.bpl__System__LStrClr_qqrpv
jmp 0x4f4f49
mov dword [ebp - 0x48], esi
mov byte [ebp - 0x44], 0
lea eax, [ebp - 0x48]
push eax
push 0
lea edx, [ebp - 0x4c]
mov eax, 0xb3
call sub.rtl250.bpl__System_Sysutils_LoadStr_qqrui
mov ecx, dword [ebp - 0x4c]
mov dl, 1
mov eax, dword [sym.imp.rtl250.bpl__System_Sysutils_EListError_]
call sub.rtl250.bpl__System_Sysutils_Exception__bctr_qqrx20System_UnicodeStringpx14System_TVarRecxi
call sub.rtl250.bpl__System__RaiseExcept_qqrv
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4f4f66
lea eax, [ebp - 0x4c]
call sub.rtl250.bpl__System__UStrClr_qqrpv
ret