Hans Leidekker : webservices: Implement WS_CHANNEL_PROPERTY_CHANNEL_TYPE.

Alexandre Julliard julliard at winehq.org
Wed Mar 29 15:02:51 CDT 2017


Module: wine
Branch: master
Commit: 9716776326df8ece5c810ff1d4fd5bff2d75e6e1
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=9716776326df8ece5c810ff1d4fd5bff2d75e6e1

Author: Hans Leidekker <hans at codeweavers.com>
Date:   Wed Mar 29 11:14:47 2017 +0200

webservices: Implement WS_CHANNEL_PROPERTY_CHANNEL_TYPE.

Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/webservices/channel.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/dlls/webservices/channel.c b/dlls/webservices/channel.c
index 7e7c409..d44fcc0 100644
--- a/dlls/webservices/channel.c
+++ b/dlls/webservices/channel.c
@@ -232,7 +232,7 @@ HRESULT WINAPI WsGetChannelProperty( WS_CHANNEL *handle, WS_CHANNEL_PROPERTY_ID
                                      ULONG size, WS_ERROR *error )
 {
     struct channel *channel = (struct channel *)handle;
-    HRESULT hr;
+    HRESULT hr = S_OK;
 
     TRACE( "%p %u %p %u %p\n", handle, id, buf, size, error );
     if (error) FIXME( "ignoring error parameter\n" );
@@ -247,7 +247,16 @@ HRESULT WINAPI WsGetChannelProperty( WS_CHANNEL *handle, WS_CHANNEL_PROPERTY_ID
         return E_INVALIDARG;
     }
 
-    hr = prop_get( channel->prop, channel->prop_count, id, buf, size );
+    switch (id)
+    {
+    case WS_CHANNEL_PROPERTY_CHANNEL_TYPE:
+        if (!buf || size != sizeof(channel->type)) hr = E_INVALIDARG;
+        else *(WS_CHANNEL_TYPE *)buf = channel->type;
+        break;
+
+    default:
+        hr = prop_get( channel->prop, channel->prop_count, id, buf, size );
+    }
 
     LeaveCriticalSection( &channel->cs );
     return hr;




More information about the wine-cvs mailing list