mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 06:33:01 +00:00
- Fix allocation of CM_RESOURCE_LIST
- Might fix bug 4354 See issue #4354 for more details. svn path=/trunk/; revision=40694
This commit is contained in:
parent
018ceb886d
commit
53767e20b1
1 changed files with 5 additions and 3 deletions
|
@ -340,9 +340,11 @@ IntVideoPortPnPStartDevice(
|
||||||
|
|
||||||
/* Save the resource list */
|
/* Save the resource list */
|
||||||
ResourceCount = AllocatedResources->List[0].PartialResourceList.Count;
|
ResourceCount = AllocatedResources->List[0].PartialResourceList.Count;
|
||||||
ResourceListSize =
|
ResourceListSize = sizeof(CM_RESOURCE_LIST);
|
||||||
FIELD_OFFSET(CM_RESOURCE_LIST, List[0].PartialResourceList.
|
|
||||||
PartialDescriptors[ResourceCount]);
|
if (ResourceCount > 1)
|
||||||
|
ResourceListSize += (ResourceCount-1) * sizeof(CM_PARTIAL_RESOURCE_DESCRIPTOR);
|
||||||
|
|
||||||
DeviceExtension->AllocatedResources = ExAllocatePool(PagedPool, ResourceListSize);
|
DeviceExtension->AllocatedResources = ExAllocatePool(PagedPool, ResourceListSize);
|
||||||
if (DeviceExtension->AllocatedResources == NULL)
|
if (DeviceExtension->AllocatedResources == NULL)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue