diff --git a/reactos/lib/setupapi/devinst.c b/reactos/lib/setupapi/devinst.c index c05b63fc00b..7ce7a69e686 100644 --- a/reactos/lib/setupapi/devinst.c +++ b/reactos/lib/setupapi/devinst.c @@ -3757,7 +3757,7 @@ BOOL WINAPI SetupDiGetClassDevPropertySheetsW( rc = GetFunctionPointer(PropPageProvider, &hModule, (PVOID*)&pPropPageProvider); if (rc != ERROR_SUCCESS) { - SetLastError(rc); + SetLastError(ERROR_INVALID_PROPPAGE_PROVIDER); goto cleanup; }