Fixed issue with ViGEm::Bus::Core::EmulationTargetPDO::EnqueueWaitDeviceReady not reporting online children

This commit is contained in:
Benjamin Höglinger-Stelzer
2020-11-03 17:03:13 +01:00
parent 27555457a7
commit 1a401ff65b
11 changed files with 29 additions and 2 deletions

View File

@@ -42,6 +42,8 @@
#include <usbioctl.h>
#include <usbiodef.h>
#include "Debugging.hpp"
PCWSTR ViGEm::Bus::Core::EmulationTargetPDO::_deviceLocation = L"Virtual Gamepad Emulation Bus";
@@ -796,7 +798,7 @@ NTSTATUS ViGEm::Bus::Core::EmulationTargetPDO::EnqueueWaitDeviceReady(WDFDEVICE
WDF_CHILD_LIST_ITERATOR_INIT(
&iterator,
WdfRetrievePendingChildren // might not be online yet
WdfRetrieveAddedChildren // might not be online yet
);
WdfChildListBeginIteration(
list,
@@ -818,6 +820,7 @@ NTSTATUS ViGEm::Bus::Core::EmulationTargetPDO::EnqueueWaitDeviceReady(WDFDEVICE
sizeof(description)
);
// ReSharper disable once CppAssignedValueIsNeverUsed
description.SerialNo = SerialNo;
status = WdfChildListRetrieveNextDevice(