wbemprox: Add empty DNSDomain to Win32_NetworkAdapterConfiguration.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51938
Signed-off-by: Louis Lenders <xerox.xerox2000x@gmail.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
(cherry picked from commit d68ea16266
)
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
This commit is contained in:
parent
4bde9d09a3
commit
b48ce9212e
|
@ -214,6 +214,7 @@ static const struct column col_networkadapterconfig[] =
|
|||
{ L"DefaultIPGateway", CIM_STRING|CIM_FLAG_ARRAY|COL_FLAG_DYNAMIC },
|
||||
{ L"Description", CIM_STRING|COL_FLAG_DYNAMIC },
|
||||
{ L"DHCPEnabled", CIM_BOOLEAN },
|
||||
{ L"DNSDomain", CIM_STRING },
|
||||
{ L"DNSHostName", CIM_STRING|COL_FLAG_DYNAMIC },
|
||||
{ L"DNSServerSearchOrder", CIM_STRING|CIM_FLAG_ARRAY|COL_FLAG_DYNAMIC },
|
||||
{ L"Index", CIM_UINT32|COL_FLAG_KEY },
|
||||
|
@ -623,6 +624,7 @@ struct record_networkadapterconfig
|
|||
const struct array *defaultipgateway;
|
||||
const WCHAR *description;
|
||||
int dhcpenabled;
|
||||
const WCHAR *dnsdomain;
|
||||
const WCHAR *dnshostname;
|
||||
const struct array *dnsserversearchorder;
|
||||
UINT32 index;
|
||||
|
@ -2942,6 +2944,7 @@ static enum fill_status fill_networkadapterconfig( struct table *table, const st
|
|||
rec->defaultipgateway = get_defaultipgateway( aa->FirstGatewayAddress );
|
||||
rec->description = heap_strdupW( aa->Description );
|
||||
rec->dhcpenabled = -1;
|
||||
rec->dnsdomain = L"";
|
||||
rec->dnshostname = get_dnshostname( aa->FirstUnicastAddress );
|
||||
rec->dnsserversearchorder = get_dnsserversearchorder( aa->FirstDnsServerAddress );
|
||||
rec->index = aa->u.s.IfIndex;
|
||||
|
|
|
@ -1203,8 +1203,10 @@ static void test_Win32_NetworkAdapterConfiguration( IWbemServices *services )
|
|||
BSTR wql = SysAllocString( L"wql" ), query = SysAllocString( L"SELECT * FROM Win32_NetworkAdapterConfiguration" );
|
||||
IEnumWbemClassObject *result;
|
||||
IWbemClassObject *obj;
|
||||
CIMTYPE type;
|
||||
HRESULT hr;
|
||||
DWORD count;
|
||||
VARIANT val;
|
||||
|
||||
hr = IWbemServices_ExecQuery( services, wql, query, 0, NULL, &result );
|
||||
ok( hr == S_OK, "got %08x\n", hr );
|
||||
|
@ -1217,6 +1219,16 @@ static void test_Win32_NetworkAdapterConfiguration( IWbemServices *services )
|
|||
check_property( obj, L"Description", VT_BSTR, CIM_STRING );
|
||||
check_property( obj, L"Index", VT_I4, CIM_UINT32 );
|
||||
check_property( obj, L"IPEnabled", VT_BOOL, CIM_BOOLEAN );
|
||||
|
||||
type = 0xdeadbeef;
|
||||
VariantInit( &val );
|
||||
hr = IWbemClassObject_Get( obj, L"DNSDomain", 0, &val, &type, NULL );
|
||||
ok( hr == S_OK, "got %08x\n", hr );
|
||||
ok( V_VT( &val ) == VT_BSTR || V_VT( &val ) == VT_NULL, "unexpected variant type 0x%x\n", V_VT( &val ) );
|
||||
ok( type == CIM_STRING, "unexpected type 0x%x\n", type );
|
||||
trace( "DNSDomain %s\n", wine_dbgstr_w(V_BSTR( &val )) );
|
||||
VariantClear( &val );
|
||||
|
||||
IWbemClassObject_Release( obj );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue