Function at 0x4064bf
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2d4
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push 4
pop edi
cmp dword [0x506bac], edi
mov esi, ecx
jl 0x4064ea
push ebx
push str.CStorageVolumes::AddVolume__s_...
push edi
call fcn.004453fb
add esp, 0xc
cmp word [ebx], 0
je 0x40650f
push ebx
call fcn.004293bb
test eax, eax
jne 0x40650f
push str._does_not_exist____abort
push edi
call fcn.004453fb
pop ecx
pop ecx
or eax, 0xffffffff
jmp 0x40689f
push dword [ebp + 0xc]
mov ecx, esi
push ebx
call fcn.0040583a
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
je 0x40655d
push ebx
call fcn.00429c05
mov ecx, dword [ebp - 4]
lea esi, [esi + ecx*4 + 4]
mov edx, dword [esi]
mov dword [edx + 0x840], eax
cmp dword [0x506bac], edi
jl 0x4065ce
push eax
mov eax, dword [esi]
push dword [eax + 0x840]
push ecx
push str._already_in_list_at_idx_i_devnum_i__i
push edi
call fcn.004453fb
add esp, 0x14
jmp 0x4065ce
mov ecx, esi
call fcn.0040580a
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
jne 0x40657b
cmp dword [0x506bac], edi
jl 0x406507
push str._no_free_idx
jmp 0x4064ff
mov edx, dword [esi]
lea ecx, [eax + 1]
cmp edx, ecx
jle 0x406586
mov ecx, edx
mov dword [esi], ecx
lea esi, [esi + eax*4 + 4]
mov ecx, dword [esi]
test ecx, ecx
je 0x406599
call fcn.00405798
jmp 0x4065ce
push 0x34f8
call fcn.0043f641
pop ecx
test eax, eax
je 0x4065b1
mov ecx, eax
call fcn.0040577b
jmp 0x4065b3
xor eax, eax
mov dword [esi], eax
cmp dword [0x506bac], edi
jl 0x4065ce
push dword [ebp - 4]
push str._add_at_idx_i
push edi
call fcn.004453fb
add esp, 0xc
mov esi, dword [esi]
mov eax, dword [ebp - 4]
mov dword [esi + 4], eax
xor eax, eax
inc eax
lea edi, [esi + 0x18]
cmp word [edi], 0
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
je 0x4065f8
push str.7f108a28_9833_4b3b_b780_2c6b5fa5c062
push edi
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x40660e
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
or dword [esi + 0x840], 0xffffffff
and dword [esi + 0x844], 0
mov eax, dword [ebp + 0xc]
test eax, eax
jne 0x406632
push 2
push 0x46d174
push ebx
call fcn.00444151
push 2
push 0x46d1d4
push ebx
mov dword [esi + 0x10], eax
call fcn.00444151
push 0
mov dword [esi + 0x10], eax
mov ebx, 0x104
push ebx
lea eax, [esi + 0x220]
push eax
push dword [esi + 0x10]
call dword [sym.imp.CFGMGR32.dll_CM_Get_Device_IDW]
cmp dword [0x506bac], 4
jl 0x40666e
push dword [ebp + 0xc]
call fcn.00444122
push eax
push str.Problem_i
push 4
call fcn.004453fb
add esp, 0xc
push dword [ebp + 8]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [ebp - 0x2d4]
push eax
call edi
push 0x44b778
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
mov dword [esi + 0x838], eax
push 0x34
lea eax, [ebp - 0xcc]
push eax
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeNameForVolumeMountPointW]
test eax, eax
je 0x4066cf
lea eax, [ebp - 0xcc]
push eax
lea eax, [esi + 0x848]
push eax
call edi
lea eax, [esi + 0x848]
cmp word [eax], 0
je 0x406713
push eax
call fcn.00405c41
mov dword [esi + 0x83c], eax
xor eax, eax
push 0x5a
push eax
mov word [ebp - 0x64], ax
lea eax, [ebp - 0x62]
push eax
call fcn.0043f481
push 0x58
lea eax, [esi + 0x850]
push eax
lea eax, [ebp - 0x64]
push eax
call fcn.0043f4eb
add esp, 0x18
lea eax, [ebp - 0x64]
jmp 0x406727
push dword [ebp + 8]
call fcn.00405c0f
mov dword [esi + 0x83c], eax
mov eax, dword [ebp + 8]
add eax, 8
push ebx
lea edi, [esi + 0x428]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
xor ebx, ebx
cmp word [edi], bx
jne 0x40675c
push ebx
lea eax, [ebp - 8]
push eax
push edi
lea eax, [ebp + 0xc]
push eax
push 0xf
push dword [ebp + 0xc]
mov dword [ebp - 8], 0x208
call dword [sym.imp.CFGMGR32.dll_CM_Get_DevNode_Registry_PropertyW]
cmp word [edi], bx
mov ebx, dword [sym.imp.USER32.dll_wsprintfW]
je 0x4067d0
lea eax, [esi + 0x844]
push eax
lea eax, [esi + 0x840]
push eax
push edi
call fcn.00429a0b
push str.DeviceHarddiskVolume
push edi
call fcn.0042549b
test eax, eax
jne 0x4067a5
push str.DeviceCdrom
push edi
call fcn.0042549b
test eax, eax
jne 0x4067a5
push str.DeviceFloppy
push edi
call fcn.0042549b
test eax, eax
je 0x4067d0
lea eax, [esi + 0x438]
push eax
lea edi, [esi + 0x8b0]
push str.._s
push edi
call ebx
add esp, 0xc
lea eax, [esi + 0x8b8]
push eax
call fcn.004293bb
test eax, eax
jne 0x4067d0
mov word [edi], ax
lea edi, [esi + 0x840]
cmp dword [edi], 0xffffffff
jne 0x406817
lea eax, [esi + 0x844]
push eax
push edi
lea eax, [ebp - 0x2d4]
push eax
call fcn.00424837
cmp dword [edi], 0xffffffff
jne 0x406817
cmp dword [esi + 0x83c], 1
jne 0x406844
push dword [ebp + 8]
mov ecx, dword [0x4fc544]
call fcn.00401db0
test eax, eax
je 0x406817
mov eax, dword [eax + 0x3a20]
mov dword [edi], eax
cmp dword [esi + 0x83c], 1
jne 0x406844
mov ecx, dword [edi]
cmp ecx, 0xffffffff
jle 0x406844
mov eax, dword [esi + 0x844]
test eax, eax
jle 0x406844
push eax
push ecx
lea eax, [esi + 0x630]
push str.DeviceHarddisk_iPartition_i
push eax
call ebx
add esp, 0x10
push dword [esi + 0x83c]
mov ecx, dword [0x4fc544]
push dword [edi]
call fcn.00401cb1
test eax, eax
je 0x406861
mov eax, dword [eax + 0x10]
mov dword [esi + 0x14], eax
mov ecx, esi
call fcn.00405d34
cmp dword [0x506bac], 4
jl 0x40689c
lea eax, [esi + 0x930]
push eax
lea eax, [esi + 0x848]
push eax
push dword [esi + 0x83c]
push dword [edi]
push dword [esi + 0x10]
push dword [ebp - 4]
push str._added_at_idx_i__devinst_u_devnum_i_devcls_i_vn_s_mp_s
push 4
call fcn.004453fb
add esp, 0x20
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 8