Hans Leidekker : wbemprox: Return an empty array for __DERIVATION.
Alexandre Julliard
julliard at winehq.org
Fri Feb 25 07:30:26 CST 2022
Module: wine
Branch: oldstable
Commit: b5eebf644a56a8e4978b000df2cad398d06ee933
URL: https://source.winehq.org/git/wine.git/?a=commit;h=b5eebf644a56a8e4978b000df2cad398d06ee933
Author: Hans Leidekker <hans at codeweavers.com>
Date: Wed Oct 13 12:48:44 2021 +0200
wbemprox: Return an empty array for __DERIVATION.
Based on a patch by Louis Lenders.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51871
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
(cherry picked from commit 2243229043b9af45376e27df55a3fa279590a9b4)
Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>
---
dlls/wbemprox/query.c | 13 +++++++++++++
dlls/wbemprox/tests/query.c | 1 +
2 files changed, 14 insertions(+)
diff --git a/dlls/wbemprox/query.c b/dlls/wbemprox/query.c
index ec2a43c3f5f..dc363475c71 100644
--- a/dlls/wbemprox/query.c
+++ b/dlls/wbemprox/query.c
@@ -1001,6 +1001,19 @@ static HRESULT get_system_propval( const struct view *view, UINT table_index, UI
if (type) *type = CIM_STRING;
return S_OK;
}
+ if (!wcsicmp( name, L"__DERIVATION" ))
+ {
+ if (ret)
+ {
+ SAFEARRAY *sa;
+ FIXME( "returning empty array for __DERIVATION\n" );
+ if (!(sa = SafeArrayCreateVector( VT_BSTR, 0, 0 ))) return E_OUTOFMEMORY;
+ V_VT( ret ) = VT_BSTR | VT_ARRAY;
+ V_ARRAY( ret ) = sa;
+ }
+ if (type) *type = CIM_STRING | CIM_FLAG_ARRAY;
+ return S_OK;
+ }
FIXME("system property %s not implemented\n", debugstr_w(name));
return WBEM_E_NOT_FOUND;
}
diff --git a/dlls/wbemprox/tests/query.c b/dlls/wbemprox/tests/query.c
index 2cb9e3c54bd..b2e2d815e2a 100644
--- a/dlls/wbemprox/tests/query.c
+++ b/dlls/wbemprox/tests/query.c
@@ -1514,6 +1514,7 @@ static void test_Win32_VideoController( IWbemServices *services )
if (hr != S_OK) break;
check_property( obj, L"__CLASS", VT_BSTR, CIM_STRING );
+ check_property( obj, L"__DERIVATION", VT_BSTR | VT_ARRAY, CIM_STRING | CIM_FLAG_ARRAY );
check_property( obj, L"__GENUS", VT_I4, CIM_SINT32 );
check_property( obj, L"__NAMESPACE", VT_BSTR, CIM_STRING );
check_property( obj, L"__PATH", VT_BSTR, CIM_STRING );
More information about the wine-cvs
mailing list