[SETUPAPI] SetupDiCreateDeviceInfoW creates phantom devices

This commit is contained in:
Eric Kohl 2022-04-17 14:29:14 +02:00
parent 7cc5163bfa
commit a355e8ad27

View file

@ -2,7 +2,7 @@
* SetupAPI device installer * SetupAPI device installer
* *
* Copyright 2000 Andreas Mohr for CodeWeavers * Copyright 2000 Andreas Mohr for CodeWeavers
* 2005-2006 Hervé Poussineau (hpoussin@reactos.org) * 2005-2006 Hervé Poussineau (hpoussin@reactos.org)
* *
* This library is free software; you can redistribute it and/or * This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public * modify it under the terms of the GNU Lesser General Public
@ -1636,6 +1636,7 @@ BOOL WINAPI SetupDiCreateDeviceInfoW(
cr = CM_Create_DevInst_ExW(&DevInst, cr = CM_Create_DevInst_ExW(&DevInst,
(DEVINSTID)DeviceName, (DEVINSTID)DeviceName,
RootDevInst, RootDevInst,
CM_CREATE_DEVINST_PHANTOM |
(CreationFlags & DICD_GENERATE_ID) ? (CreationFlags & DICD_GENERATE_ID) ?
CM_CREATE_DEVINST_GENERATE_ID : 0, CM_CREATE_DEVINST_GENERATE_ID : 0,
set->hMachine); set->hMachine);