kernel32: Reimplement GetLogicalDrives using the mountmgr

GOUJON Alexandre ale.goujon at gmail.com
Mon Jul 23 14:28:58 CDT 2012


On 07/23/2012 09:15 PM, Alexandre Julliard wrote:
> GOUJON Alexandre <ale.goujon at gmail.com> writes:
>
>> On 07/23/2012 03:03 PM, Alexandre Julliard wrote:
>>> That's very inefficient. There are better way of enumerating drives,
>>> check for instance QueryDosDevice.
>> I'm not sure QueryDosDevice is more efficient :
>> + with NULL device name, it returns every MS-DOS device which is not
>> what we want
> It's pretty much what we want. Check how it does it.
>
I may be mis-using it but on my (virtualized) Win7, QueryDosDevice with 
a NULL argument returns 6651 chars.
I truncated the output to the first strings and here's the result :

Z:
Global
D:
ACPI#PNP0C0A#0#{72631e54-78a4-11d0-bcf7-00aa00b7b32a}
PhysicalDrive0
DISPLAY5
Root#MS_L2TPMINIPORT#0000#{cac88484-7515-4c03-82e6-71a87abac361}
VDRVROOT
STORAGE#Volume#{a76e80e3-477f-11e1-b83a-806e6f6e6963}#0000000006500000#{53f5630d-b6bf-11d0-94f2-00a0c91efb8b}
SW#{eeab7790-c514-11d1-b42b-00805fc1270e}#asyncmac#{cac88484-7515-4c03-82e6-71a87abac361}
Root#SYSTEM#0000#{97ebaacb-95bd-11d0-a3ea-00a0c9223196}
DISPLAY1
Root#MS_SSTPMINIPORT#0000#{cac88484-7515-4c03-82e6-71a87abac361}

And note that using NULL, the strings are concatenated.
So getting each string is not very easy.

But if you say, it's the way to go .. will do that.



More information about the wine-devel mailing list