Function at 0x422ffd
Capabilities:
Get disk information
Get disk size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4b0
push esi
mov esi, dword [ebp + 8]
push edi
push esi
mov edi, ecx
call fcn.004165c1
cmp eax, 9
pop ecx
mov dword [ebp + 8], eax
jne 0x42302d
push 0
push dword [ebp + 0xc]
mov ecx, edi
call fcn.004235ef
jmp 0x4234bd
cmp eax, 4
push ebx
jne 0x4230a6
push 0x104
push dword [ebp + 0xc]
lea eax, [ebp - 0x130]
push eax
call fcn.00439851
lea eax, [ebp - 0x130]
push eax
call fcn.00457cb0
xor ebx, ebx
add esp, 0x10
cmp eax, ebx
je 0x42306c
lea eax, [ebp + eax - 0x130]
cmp byte [eax - 1], 0x5c
je 0x42306c
mov byte [eax], 0x5c
xor edi, edi
inc edi
push edi
call dword [sym.imp.KERNEL32.DLL_SetErrorMode]
add esi, 9
push esi
call fcn.00401ea8
pop ecx
push eax
lea eax, [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.DLL_SetVolumeLabelA]
test eax, eax
mov eax, 0x45a734
jne 0x42309c
mov eax, 0x45bf4c
push edi
push ebx
push 0xffffffffffffffff
push eax
jmp 0x4234b1
mov ecx, dword [0x467b78]
xor edi, edi
inc edi
push edi
xor ebx, ebx
push ebx
push 0xffffffffffffffff
push 0x45bf4c
call fcn.0040184e
mov eax, dword [ebp + 8]
cmp eax, 8
mov esi, dword [0x46a4f8]
mov dword [ebp - 4], esi
ja case.0x4230d4.4
jmp dword [eax*4 + 0x4234c3]
mov esi, dword [ebp + 0xc]
cmp byte [esi], bl
jne 0x4230ee
mov dword [ebp + 8], 0x100
jmp 0x423184
push str.CDRom
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x423108
mov dword [ebp + 8], 5
jmp 0x423184
push str.Removable
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x423122
mov dword [ebp + 8], 2
jmp 0x423184
push str.Fixed
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x42313c
mov dword [ebp + 8], 3
jmp 0x423184
push str.Network
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x423156
mov dword [ebp + 8], 4
jmp 0x423184
push str.Ramdisk
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x423170
mov dword [ebp + 8], 6
jmp 0x423184
push str.Unknown
push esi
call fcn.00442502
test eax, eax
pop ecx
pop ecx
jne 0x4231fb
mov dword [ebp + 8], ebx
push edi
call dword [sym.imp.KERNEL32.DLL_SetErrorMode]
xor esi, esi
mov byte [ebp + 0xf], 0x41
mov al, byte [ebp + 0xf]
mov byte [ebp - 0x1b0], al
lea eax, [ebp - 0x1b0]
push eax
mov byte [ebp - 0x1af], 0x3a
mov byte [ebp - 0x1ae], 0x5c
mov byte [ebp - 0x1ad], bl
call dword [sym.imp.KERNEL32.DLL_GetDriveTypeA]
cmp eax, dword [ebp + 8]
je 0x4231cd
cmp dword [ebp + 8], 0x100
jne 0x4231d5
cmp eax, edi
je 0x4231d5
mov al, byte [ebp + 0xf]
mov byte [ebp + esi - 0x28], al
inc esi
inc byte [ebp + 0xf]
cmp byte [ebp + 0xf], 0x5a
jbe 0x423191
mov ecx, dword [ebp - 4]
push edi
push ebx
push 0xffffffffffffffff
lea eax, [ebp - 0x28]
push eax
mov byte [ebp + esi - 0x28], bl
call fcn.0040184e
cmp byte [ebp - 0x28], bl
jne case.0x4230d4.4
mov eax, edi
jmp 0x4234bc
push 0x104
push dword [ebp + 0xc]
lea eax, [ebp - 0x130]
push eax
call fcn.00439851
lea eax, [ebp - 0x130]
push eax
call fcn.00457cb0
add esp, 0x10
cmp eax, ebx
je 0x423239
lea eax, [ebp + eax - 0x130]
cmp byte [eax - 1], 0x5c
je 0x423239
mov byte [eax], 0x5c
push edi
call dword [sym.imp.KERNEL32.DLL_SetErrorMode]
mov eax, 0xff
push eax
lea ecx, [ebp - 0x4b0]
push ecx
lea ecx, [ebp - 4]
push ecx
lea ecx, [ebp - 8]
push ecx
lea ecx, [ebp + 0xc]
push ecx
push eax
lea eax, [ebp - 0x230]
push eax
lea eax, [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.DLL_GetVolumeInformationA]
test eax, eax
je case.0x4230d4.0
mov eax, dword [ebp + 8]
dec eax
dec eax
je 0x4232a5
dec eax
je 0x42329a
dec eax
dec eax
jne case.0x4230d4.4
push 0x18
push ebx
push dword [ebp + 0xc]
mov ecx, esi
call fcn.00401c1f
jmp case.0x4230d4.4
lea eax, [ebp - 0x230]
jmp 0x42349c
lea eax, [ebp - 0x4b0]
jmp 0x42349c
push 0x104
push dword [ebp + 0xc]
lea eax, [ebp - 0x130]
push eax
call fcn.00439851
lea eax, [ebp - 0x130]
push eax
call fcn.00457cb0
add esp, 0x10
cmp eax, ebx
je 0x4232e7
lea eax, [ebp + eax - 0x130]
cmp byte [eax - 1], 0x5c
je 0x4232e7
mov byte [eax], 0x5c
push edi
call dword [sym.imp.KERNEL32.DLL_SetErrorMode]
lea eax, [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.DLL_GetDriveTypeA]
sub eax, ebx
push edi
push ebx
mov ecx, esi
push 0xffffffffffffffff
je 0x4233d2
dec eax
dec eax
je 0x423347
dec eax
je 0x42333d
dec eax
je 0x423333
dec eax
je 0x423329
dec eax
je 0x42331f
push ebx
jmp 0x4234b7
push str.RAMDisk
jmp 0x4234a3
push str.CDROM
jmp 0x4234a3
push str.Network
jmp 0x4234a3
push str.Fixed
jmp 0x4234a3
push str.Removable
jmp 0x4234a3
push 0x104
push dword [ebp + 0xc]
lea eax, [ebp - 0x130]
push eax
call fcn.00439851
lea eax, [ebp - 0x130]
push eax
call fcn.00457cb0
add esp, 0x10
cmp eax, ebx
je 0x423388
lea eax, [ebp + eax - 0x130]
cmp byte [eax - 1], 0x5c
je 0x423388
mov byte [eax], 0x5c
push edi
call dword [sym.imp.KERNEL32.DLL_SetErrorMode]
lea eax, [ebp + 0xc]
push eax
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.DLL_GetDiskFreeSpaceA]
test eax, eax
je 0x4233b4
xor eax, eax
jmp 0x4233ba
call dword [sym.imp.KERNEL32.DLL_GetLastError]
sub eax, ebx
push edi
push ebx
push 0xffffffffffffffff
je 0x4233fa
sub eax, 3
je 0x4233f0
sub eax, 0x10
mov ecx, esi
je 0x4233e6
dec eax
dec eax
je 0x4233dc
push str.Unknown
jmp 0x4234a3
push str.NotReady
jmp 0x4234a3
push str.ReadOnly
jmp 0x4234a3
push str.Invalid
jmp 0x4234a1
push str.Ready
jmp 0x4234a1
mov eax, dword [ebp + 0xc]
cmp byte [eax], bl
jne 0x423433
push ebx
push 0x80
lea eax, [ebp - 0x2b0]
push eax
push str.status_cdaudio_mode
call dword [sym.imp.WINMM.dll_mciSendStringA]
test eax, eax
je 0x423496
push edi
push ebx
push 0xffffffffffffffff
push ebx
mov ecx, esi
jmp 0x4234b7
push eax
push str.open__s_type_cdaudio_alias_cd_wait_shareable
lea eax, [ebp - 0x3b0]
push 0x100
push eax
call fcn.0040a6d3
mov esi, dword [sym.imp.WINMM.dll_mciSendStringA]
add esp, 0x10
push ebx
push ebx
push ebx
lea eax, [ebp - 0x3b0]
push eax
call esi
test eax, eax
jne 0x423489
push ebx
push 0x80
lea eax, [ebp - 0x2b0]
push eax
push str.status_cd_mode
call esi
push ebx
push ebx
push ebx
push str.close_cd_wait
mov dword [ebp + 0xc], eax
call esi
cmp dword [ebp + 0xc], ebx
je 0x423493
mov ecx, dword [ebp - 4]
push edi
push ebx
push 0xffffffffffffffff
push ebx
jmp 0x4234b7
mov esi, dword [ebp - 4]
lea eax, [ebp - 0x2b0]
push edi
push ebx
push 0xffffffffffffffff
push eax
mov ecx, esi
call fcn.0040184e
push edi
push ebx
push 0xffffffffffffffff
push 0x45a734
mov ecx, dword [0x467b78]
call fcn.0040184e
pop ebx
pop edi
pop esi
leave
ret 8