Commit 04a84bc7 authored by Robert Wilhelm's avatar Robert Wilhelm Committed by Alexandre Julliard

wshom.ocx: Downgrade FIXME to WARN for unsupported interfaces.

Scripting always checks for DispatchEx interface before falling back to Dispatch.
parent e9592991
...@@ -16,6 +16,9 @@ ...@@ -16,6 +16,9 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/ */
#define COBJMACROS
#include "dispex.h"
#include "wshom_private.h" #include "wshom_private.h"
#include "wshom.h" #include "wshom.h"
...@@ -30,17 +33,16 @@ static HRESULT WINAPI WshNetwork2_QueryInterface(IWshNetwork2 *iface, REFIID rii ...@@ -30,17 +33,16 @@ static HRESULT WINAPI WshNetwork2_QueryInterface(IWshNetwork2 *iface, REFIID rii
if(IsEqualGUID(riid, &IID_IUnknown) || if(IsEqualGUID(riid, &IID_IUnknown) ||
IsEqualGUID(riid, &IID_IDispatch) || IsEqualGUID(riid, &IID_IDispatch) ||
IsEqualGUID(riid, &IID_IWshNetwork) || IsEqualGUID(riid, &IID_IWshNetwork) ||
IsEqualGUID(riid, &IID_IWshNetwork2)) IsEqualGUID(riid, &IID_IWshNetwork2)) {
{
*ppv = iface; *ppv = iface;
}else { IUnknown_AddRef((IUnknown*)*ppv);
FIXME("Unknown iface %s\n", debugstr_guid(riid)); return S_OK;
}
else {
WARN("interface not supported %s\n", debugstr_guid(riid));
*ppv = NULL; *ppv = NULL;
return E_NOINTERFACE; return E_NOINTERFACE;
} }
IUnknown_AddRef((IUnknown*)*ppv);
return S_OK;
} }
static ULONG WINAPI WshNetwork2_AddRef(IWshNetwork2 *iface) static ULONG WINAPI WshNetwork2_AddRef(IWshNetwork2 *iface)
......
...@@ -700,6 +700,8 @@ static void test_wshnetwork(void) ...@@ -700,6 +700,8 @@ static void test_wshnetwork(void)
check_interface(disp, &IID_IWshNetwork, TRUE); check_interface(disp, &IID_IWshNetwork, TRUE);
check_interface(disp, &IID_IWshNetwork2, TRUE); check_interface(disp, &IID_IWshNetwork2, TRUE);
check_interface(disp, &IID_IDispatchEx, FALSE);
check_interface(disp, &IID_IObjectWithSite, FALSE);
IDispatch_Release(disp); IDispatch_Release(disp);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment