|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [win-pv-devel] [PATCH 2/3] Only add device if the guid matches
The IDeviceCreator::OnDeviceAdded() method should only be called for
devices matching the GUID specified to the CDeviceList object creator.
Signed-off-by: Paul Durrant <paul.durrant@xxxxxxxxxx>
---
src/xenagent/devicelist.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/xenagent/devicelist.cpp b/src/xenagent/devicelist.cpp
index 98caffb..2c110bc 100644
--- a/src/xenagent/devicelist.cpp
+++ b/src/xenagent/devicelist.cpp
@@ -218,7 +218,8 @@ void CDeviceList::OnDeviceEvent(DWORD evt, LPVOID data)
case DBT_DEVICEARRIVAL:
if (hdr->dbch_devicetype == DBT_DEVTYP_DEVICEINTERFACE) {
itf = (PDEV_BROADCAST_DEVICEINTERFACE)hdr;
- OnDeviceAdded(Convert((const wchar_t*)itf->dbcc_name));
+ if (itf->dbcc_classguid == m_guid)
+ OnDeviceAdded(Convert((const wchar_t*)itf->dbcc_name));
}
break;
--
2.5.3
_______________________________________________
win-pv-devel mailing list
win-pv-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |