- Correctly double-null-terminate hardware IDs
CORE-11271 #resolve

svn path=/trunk/; revision=71354
This commit is contained in:
Thomas Faber 2016-05-19 10:15:15 +00:00
parent 63318080ba
commit 407f2e8218

View file

@ -29,7 +29,7 @@ Bus_PlugInDevice (
NTSTATUS status;
ULONG index;
WCHAR temp[256];
PLIST_ENTRY entry;
PLIST_ENTRY entry;
PAGED_CODE ();
@ -110,13 +110,13 @@ Bus_PlugInDevice (
index += swprintf(&temp[index],
L"ACPI\\%hs",
Device->pnp.hardware_id);
index++;
temp[index++] = UNICODE_NULL;
index += swprintf(&temp[index],
L"*%hs",
Device->pnp.hardware_id);
index++;
temp[++index] = UNICODE_NULL;
temp[index++] = UNICODE_NULL;
temp[index++] = UNICODE_NULL;
pdoData->HardwareIDs = ExAllocatePoolWithTag(NonPagedPool, index*sizeof(WCHAR), 'DpcA');