[prev in list] [next in list] [prev in thread] [next in thread]
List: win-pv-devel
Subject: [win-pv-devel] [PATCH 2/3] Only add device if the guid matches
From: Paul Durrant <paul.durrant () citrix ! com>
Date: 2017-03-30 16:52:30
Message-ID: 1490892751-1944-2-git-send-email-paul.durrant () citrix ! com
[Download RAW message or body]
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@citrix.com>
---
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@lists.xenproject.org
https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic