[SETUPAPI]

- SetupDiRegisterDeviceInfo shouldn't fail if a device instance already exists
- MSDN documentation for this function states: "If [SPRDI_FIND_DUPS] is not specified, the device instance is registered regardless of whether a device instance already exists for it."

svn path=/trunk/; revision=59702
This commit is contained in:
Cameron Gutman 2013-08-11 21:19:35 +00:00
parent c673f80b25
commit 975aee1a7c

View file

@ -1911,7 +1911,8 @@ BOOL WINAPI SetupDiRegisterDeviceInfo(
ParentDevInst,
CM_CREATE_DEVINST_NORMAL | CM_CREATE_DEVINST_DO_NOT_INSTALL,
set->hMachine);
if (cr != CR_SUCCESS)
if (cr != CR_SUCCESS &&
cr != CR_ALREADY_SUCH_DEVINST)
{
dwError = ERROR_NO_SUCH_DEVINST;
}