[NTOSKRNL]

- Fix to PpSetCustomTargetEvent(), not to make caller wait forever in case it provided an event it waits for
- Patch by Pierre Schweitzer

svn path=/trunk/; revision=48626
This commit is contained in:
Timo Kreuzer
2010-08-26 15:25:33 +00:00
parent 6ddec3f063
commit e04ebf1980
+13
View File
@@ -132,12 +132,25 @@ PpSetCustomTargetEvent(IN PDEVICE_OBJECT DeviceObject,
ASSERT(NotificationStructure != NULL);
ASSERT(DeviceObject != NULL);
if (SyncEvent)
{
ASSERT(SyncStatus);
*SyncStatus = STATUS_PENDING;
}
/* That call is totally wrong but notifications handler must be fixed first */
IopNotifyPlugPlayNotification(DeviceObject,
EventCategoryTargetDeviceChange,
&GUID_PNP_CUSTOM_NOTIFICATION,
NotificationStructure,
NULL);
if (SyncEvent)
{
KeSetEvent(SyncEvent, IO_NO_INCREMENT, FALSE);
*SyncStatus = STATUS_SUCCESS;
}
return STATUS_SUCCESS;
}