[SETUPAPI] Improve CM_Disable_DevNode_Ex

Replace the call to PNP_DeviceInstanceAction(PNP_DEVINST_DISABLE) by a call to PNP_DisableDevInst() because PNP_DeviceInstanceAction(PNP_DEVINST_DISABLE) is a no-op.
This commit is contained in:
Eric Kohl 2020-03-07 13:26:53 +01:00
parent 02f68dcb7a
commit 3909ebcf35

View file

@ -1830,11 +1830,12 @@ CM_Disable_DevNode_Ex(
RpcTryExcept
{
ret = PNP_DeviceInstanceAction(BindingHandle,
PNP_DEVINST_DISABLE,
ulFlags,
lpDevInst,
NULL);
ret = PNP_DisableDevInst(BindingHandle,
lpDevInst,
NULL,
NULL,
0,
ulFlags);
}
RpcExcept(EXCEPTION_EXECUTE_HANDLER)
{