Function at 0x4d77f0
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffcfc
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x2fc], ecx
mov dword [ebp - 4], ecx
mov dword [ebp - 8], ecx
mov edi, edx
mov dword [ebp - 0xc], eax
xor eax, eax
push ebp
push 0x4d7c7f
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
mov edx, edi
call fcn.00426594
mov edx, dword [0x4d7240]
call sub.rtl250.bpl__System__AsClass_qqrxp14System_TObjectp17System_TMetaClass
lea edx, [ebp - 4]
call fcn.00412564
mov dl, 1
mov eax, dword [0x4b5ff0]
call fcn.004bbecc
mov dword [ebp - 0x14], eax
xor edx, edx
push ebp
push 0x4d7c52
push dword fs:[edx]
mov dword fs:[edx], esp
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
mov esi, dword [eax + 8]
dec esi
test esi, esi
jl 0x4d78d3
inc esi
xor ebx, ebx
cmp edi, ebx
je 0x4d78cf
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
mov edx, ebx
call fcn.00426594
mov edx, dword [0x4d7240]
call sub.rtl250.bpl__System__IsClass_qqrxp14System_TObjectp17System_TMetaClass
test al, al
je 0x4d78cf
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
mov edx, ebx
call fcn.00426594
mov edx, dword [0x4d7240]
call sub.rtl250.bpl__System__AsClass_qqrxp14System_TObjectp17System_TMetaClass
lea edx, [ebp - 0x2fc]
call fcn.00412564
mov edx, dword [ebp - 0x2fc]
mov ecx, dword [ebp - 4]
mov eax, dword [sym.imp.AxComponentsRTL.bpl__Axrtl_System_Strutils_StrUtils_]
call sub.AxComponentsRTL.bpl__Axrtl_System_Strutils_StrUtils_SameText_qqrx20System_UnicodeStringt1
test al, al
je 0x4d78cf
mov edx, ebx
mov eax, dword [ebp - 0x14]
call fcn.004bc19c
inc ebx
dec esi
jne 0x4d786b
mov eax, dword [ebp - 0x14]
cmp dword [eax + 8], 0
jne 0x4d7931
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 8]
call fcn.0040c76c
mov ecx, dword [eax + 4]
mov edx, dword [ebp - 4]
mov eax, dword [0x40bc48]
call fcn.0040cf1c
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 5
jne 0x4d7c3c
push 4
push 0
mov eax, dword [ebp - 4]
call sub.rtl250.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_MoveFileExW
test eax, eax
je 0x4d7924
xor eax, eax
mov dword [ebp - 0x10], eax
jmp 0x4d7c3c
call sub.kernel32.dll_GetLastError
mov dword [ebp - 0x10], eax
jmp 0x4d7c3c
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 8]
call fcn.0040c76c
mov ecx, dword [eax + 4]
mov edx, dword [ebp - 4]
mov eax, dword [0x40bc48]
call fcn.0040cf1c
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x4d795f
call sub.rtl250.bpl__System__TryFinallyExit_qqrv
jmp 0x4d7c59
xor ecx, ecx
mov edx, dword [ebp - 4]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__AssignText_qqrr15System_TTextRecpxbxus
call sub.rtl250.bpl__System___IOTest_qqrv
xor edx, edx
push ebp
push 0x4d799c
push dword fs:[edx]
mov dword fs:[edx], esp
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__RewritText_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4d79c7
xor eax, eax
push ebp
push 0x4d7c35
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 0x14]
mov esi, dword [eax + 8]
dec esi
test esi, esi
jl 0x4d7c17
inc esi
xor ebx, ebx
mov edx, ebx
mov eax, dword [ebp - 0x14]
call fcn.004bbe48
mov edx, eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
call fcn.00426594
mov edx, dword [0x4d7240]
call sub.rtl250.bpl__System__AsClass_qqrxp14System_TObjectp17System_TMetaClass
mov edi, eax
mov edx, dword [edi + 0x2c]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
mov edx, dword [edi + 0x3c]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
mov edx, dword [edi + 0x38]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
lea eax, [ebp - 8]
push eax
mov eax, dword [edi + 0x28]
mov dword [ebp - 0x304], eax
mov byte [ebp - 0x300], 0
lea edx, [ebp - 0x304]
xor ecx, ecx
mov eax, 0x4d7c9c
call sub.rtl250.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
mov edx, dword [ebp - 8]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
push dword [edi + 0x24]
push dword [edi + 0x20]
lea eax, [ebp - 0x1c]
call sub.AxComponentsRTL.bpl__Axrtl_System_Ioutils_TFileHelper_DateTimeToFileTime_qqr16System_TDateTime
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x304], eax
mov byte [ebp - 0x300], 0
lea edx, [ebp - 0x304]
xor ecx, ecx
mov eax, 0x4d7c9c
call sub.rtl250.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
mov edx, dword [ebp - 8]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x304], eax
mov byte [ebp - 0x300], 0
lea edx, [ebp - 0x304]
xor ecx, ecx
mov eax, 0x4d7c9c
call sub.rtl250.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
mov edx, dword [ebp - 8]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
push dword [edi + 0x1c]
push dword [edi + 0x18]
lea eax, [ebp - 0x1c]
call sub.AxComponentsRTL.bpl__Axrtl_System_Ioutils_TFileHelper_DateTimeToFileTime_qqr16System_TDateTime
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x304], eax
mov byte [ebp - 0x300], 0
lea edx, [ebp - 0x304]
xor ecx, ecx
mov eax, 0x4d7c9c
call sub.rtl250.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
mov edx, dword [ebp - 8]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x304], eax
mov byte [ebp - 0x300], 0
lea edx, [ebp - 0x304]
xor ecx, ecx
mov eax, 0x4d7c9c
call sub.rtl250.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
mov edx, dword [ebp - 8]
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0UString_qqrr15System_TTextRecx20System_UnicodeString
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
mov dx, 0x2a
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
mov dx, 0xa
call sub.rtl250.bpl__System__Write0WChar_qqrr15System_TTextRecb
call sub.rtl250.bpl__System__Flush_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
inc ebx
dec esi
jne 0x4d79e7
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4d7c3c
lea eax, [ebp - 0x2f8]
call sub.rtl250.bpl__System__Close_qqrr15System_TTextRec
call sub.rtl250.bpl__System___IOTest_qqrv
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4d7c59
lea eax, [ebp - 0x14]
call sub.rtl250.bpl__System_Sysutils_FreeAndNil_qqrpv
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4d7c86
lea eax, [ebp - 0x2fc]
call sub.rtl250.bpl__System__UStrClr_qqrpv
lea eax, [ebp - 8]
mov edx, 2
call sub.rtl250.bpl__System__UStrArrayClr_qqrpvi
ret