mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 21:32:56 +00:00
[SETUPAPI] Do not fail enumeration on invalid device interface keys (#7741)
Necessary for drivers, which install multiple device interfaces and all interfaces might not be available for this device. CORE-17285
This commit is contained in:
parent
9aa299bea4
commit
ecf4001e6f
1 changed files with 6 additions and 2 deletions
|
@ -212,8 +212,12 @@ SETUP_CreateInterfaceList(
|
||||||
|
|
||||||
/* Read SymbolicLink value */
|
/* Read SymbolicLink value */
|
||||||
rc = RegQueryValueExW(hReferenceKey, SymbolicLink, NULL, &dwRegType, NULL, &dwLength);
|
rc = RegQueryValueExW(hReferenceKey, SymbolicLink, NULL, &dwRegType, NULL, &dwLength);
|
||||||
if (rc != ERROR_SUCCESS )
|
if (rc != ERROR_SUCCESS)
|
||||||
goto cleanup;
|
{
|
||||||
|
/* Skip device interface with invalid reference value (i.e. interface not actually available for this device) */
|
||||||
|
RegCloseKey(hReferenceKey);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if (dwRegType != REG_SZ)
|
if (dwRegType != REG_SZ)
|
||||||
{
|
{
|
||||||
rc = ERROR_GEN_FAILURE;
|
rc = ERROR_GEN_FAILURE;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue