Function at 0x422a30
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
mov ecx, 6
push 0
push 0
dec ecx
jne 0x422a38
push ebx
push esi
push edi
mov dword [ebp - 8], edx
xor eax, eax
push ebp
push 0x422d3d
push dword fs:[eax]
mov dword fs:[eax], esp
lea edx, [ebp - 0x1c]
mov eax, dword [ebp - 8]
call fcn.0041cea4
mov eax, dword [ebp - 0x1c]
call sub.rtl160.bpl__System__UStrLen_qqrx20System_UnicodeString
test eax, eax
jle 0x422a77
lea edx, [ebp - 4]
mov eax, dword [ebp - 8]
call fcn.0041cea4
jmp 0x422a82
lea edx, [ebp - 4]
mov eax, dword [ebp - 8]
call fcn.0041cf88
mov eax, dword [ebp - 4]
call sub.rtl160.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_GetDriveTypeW
cmp eax, 6
ja case.0x422a99.0
jmp dword [eax*4 + 0x422aa0]
mov edx, 1
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
lea edx, [ebp - 0x24]
mov eax, dword [ebp - 8]
call fcn.0041d1ac
mov eax, dword [ebp - 0x24]
lea edx, [ebp - 0x20]
call sub.rtl160.bpl__System_Sysutils_UpperCase_qqrx20System_UnicodeString
mov eax, dword [ebp - 0x20]
push eax
lea edx, [ebp - 0x28]
mov eax, 0x422d58
call sub.rtl160.bpl__System_Sysutils_UpperCase_qqrx20System_UnicodeString
mov eax, dword [ebp - 0x28]
pop edx
call sub.rtl160.bpl__System_Pos_qqrx20System_UnicodeStringt1
test eax, eax
jle 0x422b11
mov edx, 2
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
mov edx, 3
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
mov edx, 4
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
mov edx, 6
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
mov edx, 7
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
mov edx, 8
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422b66
xor edx, edx
mov eax, dword [ebp - 8]
call fcn.0041d290
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x54]
add eax, 0xfffffffd
sub eax, 2
jae 0x422cbc
lea edx, [ebp - 0x2c]
mov eax, dword [0x4093b4]
call fcn.00409070
mov ecx, dword [ebp - 0x2c]
mov dl, 1
mov eax, dword [0x4078fc]
call fcn.00408708
mov dword [ebp - 0x14], eax
xor eax, eax
push ebp
push 0x422cb5
push dword fs:[eax]
mov dword fs:[eax], esp
lea edx, [ebp - 0x30]
mov eax, dword [0x41dbac]
call fcn.0041f990
mov ecx, dword [ebp - 0x30]
mov dl, 1
mov eax, dword [0x41beac]
call fcn.0041eefc
mov dword [ebp - 0x18], eax
xor eax, eax
push ebp
push 0x422c98
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0x10], 0x400
mov eax, dword [ebp - 0x10]
push eax
call sub.rtl160.bpl__System_GetMemory_qi
pop ecx
mov dword [ebp - 0xc], eax
xor eax, eax
push ebp
push 0x422c7b
push dword fs:[eax]
mov dword fs:[eax], esp
mov edx, dword [ebp - 0x10]
mov eax, dword [ebp - 0xc]
call fcn.00401e9c
lea eax, [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov eax, dword [0x40d1d8]
call fcn.0040dce8
test al, al
je 0x422c63
mov eax, dword [ebp - 0xc]
mov ebx, dword [eax]
dec ebx
test ebx, ebx
jl 0x422c4d
inc ebx
xor esi, esi
lea edi, [esi + esi*2]
mov eax, dword [ebp - 0xc]
mov edx, dword [eax + edi*8 + 8]
mov eax, dword [ebp - 0x14]
call fcn.00408860
mov eax, dword [ebp - 0xc]
push dword [eax + edi*8 + 0x14]
push dword [eax + edi*8 + 0x10]
mov eax, dword [ebp - 0x18]
call fcn.0041f054
inc esi
dec ebx
jne 0x422c24
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
call fcn.0041d828
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 8]
call fcn.0041d908
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x422c82
mov eax, dword [ebp - 0xc]
push eax
call sub.rtl160.bpl__System_FreeMemory_qpv
pop ecx
ret
mov eax, dword [ebp - 8]
cmp dword [eax + 0x54], 4
jne 0x422d0a
mov eax, dword [ebp - 8]
call fcn.0041d7d0
mov ebx, dword [eax + 8]
dec ebx
test ebx, ebx
jl 0x422d0a
inc ebx
xor esi, esi
mov eax, dword [ebp - 8]
call fcn.0041d7d0
mov edx, esi
call fcn.004084f0
mov edx, eax
mov eax, dword [0x40d1d8]
call fcn.0040e3e0
test al, al
je 0x422d06
mov edx, 5
mov eax, dword [ebp - 8]
call fcn.0041d290
jmp 0x422d0a
inc esi
dec ebx
jne 0x422cd8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x422d44
lea eax, [ebp - 0x30]
call sub.rtl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
lea eax, [ebp - 0x2c]
call sub.rtl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
lea eax, [ebp - 0x28]
mov edx, 4
call sub.rtl160.bpl__System__UStrArrayClr_qqrpvi
lea eax, [ebp - 4]
call sub.rtl160.bpl__System__UStrClr_qqrpv
ret