[NTOSKRNL] On device map freeing, make directory object temporary again

This commit is contained in:
Pierre Schweitzer 2019-06-01 13:59:13 +02:00
parent 221ed88141
commit 848f7bb687
No known key found for this signature in database
GPG key ID: 7545556C3D585B0B

View file

@ -189,7 +189,8 @@ ObfDereferenceDeviceMap(IN PDEVICE_MAP DeviceMap)
KeReleaseGuardedMutex(&ObpDeviceMapLock);
/* Dereference the DOS Devices Directory and free the Device Map */
ObDereferenceObject(DeviceMap->DosDevicesDirectory );
ObMakeTemporaryObject(DeviceMap->DosDevicesDirectory);
ObDereferenceObject(DeviceMap->DosDevicesDirectory);
ExFreePoolWithTag(DeviceMap, 'mDbO');
}