From: Mohamad Al-Jaf mohamadaljaf@gmail.com
--- dlls/windows.networking.hostname/hostname.c | 8 ++++++-- dlls/windows.networking.hostname/tests/hostname.c | 8 ++++---- 2 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/dlls/windows.networking.hostname/hostname.c b/dlls/windows.networking.hostname/hostname.c index 39047982771..42eb4aef014 100644 --- a/dlls/windows.networking.hostname/hostname.c +++ b/dlls/windows.networking.hostname/hostname.c @@ -128,8 +128,12 @@ static HRESULT WINAPI hostname_get_IPInformation( IHostName *iface, IIPInformati
static HRESULT WINAPI hostname_get_RawName( IHostName *iface, HSTRING *value ) { - FIXME( "iface %p, value %p stub!\n", iface, value ); - return E_NOTIMPL; + struct hostname *impl = impl_from_IHostName( iface ); + + TRACE( "iface %p, value %p stub!\n", iface, value ); + + if (!value) return E_INVALIDARG; + return WindowsDuplicateString( impl->rawname, value ); }
static HRESULT WINAPI hostname_get_DisplayName( IHostName *iface, HSTRING *value ) diff --git a/dlls/windows.networking.hostname/tests/hostname.c b/dlls/windows.networking.hostname/tests/hostname.c index b81fe2173b4..e37c957a7a0 100644 --- a/dlls/windows.networking.hostname/tests/hostname.c +++ b/dlls/windows.networking.hostname/tests/hostname.c @@ -89,12 +89,12 @@ static void test_HostnameStatics(void) ok( hostname != NULL, "got NULL hostname %p.\n", hostname );
hr = IHostName_get_RawName( hostname, NULL ); - todo_wine ok( hr == E_INVALIDARG, "got hr %#lx.\n", hr ); + ok( hr == E_INVALIDARG, "got hr %#lx.\n", hr ); hr = IHostName_get_RawName( hostname, &rawname ); - todo_wine ok( hr == S_OK, "got hr %#lx.\n", hr ); + ok( hr == S_OK, "got hr %#lx.\n", hr ); hr = WindowsCompareStringOrdinal( str, rawname, &res ); - todo_wine ok( hr == S_OK, "got hr %#lx.\n", hr ); - todo_wine ok( !res, "got unexpected string %s.\n", debugstr_hstring(rawname) ); + ok( hr == S_OK, "got hr %#lx.\n", hr ); + ok( !res, "got unexpected string %s.\n", debugstr_hstring(rawname) );
WindowsDeleteString( str ); WindowsDeleteString( rawname );