Function at 0x1002f4d0
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1011f0b8
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push ebx
push esi
push edi
mov eax, dword [0x1016e750]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x2c], edx
mov edi, ecx
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x30], 0
mov dword [ebp - 4], 0
call fcn.10022690
mov ecx, eax
xor eax, eax
test ecx, ecx
setne al
test eax, eax
jne 0x1002f52a
push 0x80004005
call fcn.100223c0
mov eax, dword [ecx]
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x18], esi
mov byte [ebp - 4], 1
mov eax, dword [ebp + 8]
cmp dword [eax - 0xc], 0
jge 0x1002f54c
push 0x80070057
call fcn.100223c0
movzx eax, word [eax]
push eax
call fcn.10104fde
mov ebx, eax
add esp, 4
mov dword [ebp - 0x1c], ebx
lea ecx, [ebx - 0x41]
cmp ecx, 0x19
ja 0x1002f79c
mov ecx, dword [ebp + 8]
cmp dword [ecx - 0xc], 1
jge 0x1002f57c
push 0x80070057
call fcn.100223c0
cmp word [ecx + 2], 0x3a
jne 0x1002f79c
cmp dword [0x101726a8], 0
jne 0x1002f595
call fcn.10030940
push 0x10175220
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebx*4 + 0x10175134]
or ebx, 0xffffffff
mov dword [ebp - 0x14], eax
cmp eax, ebx
mov eax, dword [ebp - 0x1c]
jne 0x1002f721
push eax
lea eax, [ebp - 0x10]
push str._c:_
push eax
call fcn.10044f30
add esp, 0xc
push dword [eax]
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
mov ecx, dword [ebp - 0x10]
mov edx, ebx
add ecx, 0xfffffff0
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x20], ecx
add ecx, 0xc
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x1002f5fa
mov edx, dword [ebp - 0x20]
push edx
mov ecx, dword [edx]
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x1c]
cmp eax, 1
push 0x1012ec60
cmove eax, ebx
mov dword [ebp - 0x14], eax
mov dword [ecx*4 + 0x10175134], eax
lea eax, [ecx*4 + 0x1017519c]
mov ecx, eax
mov dword [ebp - 0x24], eax
call fcn.100240c0
cmp dword [ebp - 0x14], 0xffffffff
je 0x1002f734
push 0x1012ec60
lea ecx, [ebp - 0x10]
call fcn.10023fc0
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x1c]
push eax
lea eax, [ebp - 0x1c]
push 0x1013a14c
push eax
call fcn.10044f30
add esp, 0xc
mov dword [ebp - 0x20], eax
mov byte [ebp - 4], 3
mov edi, 1
mov ecx, dword [ebp - 0x10]
mov edx, dword [ecx - 8]
sub edi, dword [ecx - 4]
sub edx, 0x104
or edx, edi
jge 0x1002f685
push 0x104
lea ecx, [ebp - 0x10]
call fcn.100249c0
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x20]
push 0x104
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 2
mov edi, eax
call fcn.10024080
push ecx
lea ecx, [ebp - 0x10]
call fcn.10024210
test edi, edi
je 0x1002f710
push ecx
mov ecx, dword [ebp - 0x10]
mov esi, esp
lea ecx, [ecx - 0x10]
call fcn.10024750
add eax, 0x10
lea ecx, [ebp - 0x20]
mov dword [esi], eax
call fcn.1002f800
add esp, 4
mov esi, dword [ebp - 0x24]
mov ecx, esi
push eax
mov byte [ebp - 4], 4
call fcn.100244b0
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 2
call fcn.10024080
push esi
lea ecx, [ebp - 0x18]
call fcn.100244b0
mov esi, dword [ebp - 0x18]
push ecx
mov eax, esp
push esi
push dword [ebp - 0x10]
push str.ResolveDosDrive:_DeviceFileName_s____DosDriveCache_s
push eax
call fcn.10044f30
add esp, 0x10
call fcn.1002f220
add esp, 4
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 1
call fcn.10024080
mov edi, dword [ebp - 0x28]
jmp 0x1002f734
lea eax, [eax*4 + 0x1017519c]
push eax
lea ecx, [ebp - 0x18]
call fcn.100244b0
mov esi, dword [ebp - 0x18]
push 0x10175220
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [ebp - 0x2c], 0
je 0x1002f77b
cmp dword [ebp - 0x14], 4
je 0x1002f77b
push 0x1012ec60
mov ecx, edi
call fcn.10023fc0
lea ecx, [ebp - 0x18]
call fcn.10024080
lea ecx, [ebp + 8]
call fcn.10024080
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
add esi, 0xfffffff0
mov ecx, esi
call fcn.10024750
add eax, 0x10
mov byte [ebp - 4], 0
mov dword [edi], eax
mov ecx, ebx
lea eax, [esi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jmp 0x1002f7be
push 0x1012ec60
mov ecx, edi
call fcn.10023fc0
add esi, 0xfffffff0
mov byte [ebp - 4], 0
or ebx, 0xffffffff
mov eax, ebx
lea ecx, [esi + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x1002f7c8
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp + 8]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x1002f7e9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret