Reduce called buffer size in QueryDosDevice as it was not returning a correct value.

This commit is contained in:
2020-10-24 14:41:22 +01:00
parent 95ebde2470
commit 0f037fbf2b

View File

@@ -56,12 +56,12 @@ DeviceInfoList* ListDevices()
return NULL;
}
QueryDosDevice(NULL, physical, 65536);
QueryDosDevice(NULL, physical, 65535);
for(pos = physical; *pos; pos += strlen(pos) + 1)
{
if((strncmp(pos, "PhysicalDrive", 13) != 0 && strncmp(pos, "CdRom", 5) != 0) && strncmp(pos, "Tape", 4) != 0)
{ continue; }
continue;
sprintf_s(physId, 4096, "\\\\.\\%s", pos);