2008/9/28 Louis. Lenders xerox_xerox2000@yahoo.co.uk:
Rob Shearman <robertshearman <at> gmail.com> writes:
2008/9/15 Louis Lenders <xerox_xerox2000 <at> yahoo.co.uk>:
Rob Shearman <robertshearman <at> gmail.com> writes:
I suggest you write a test case that replicates what the application does and either send it to wine-patches with appropriate todo_wine's or attach it to the bug.
Well, it looks like the app is only checking if the uuid of the
interface is defined using Context_QueryInterface, and that's about it. It doesn't really seem to try to use anything from it, as Erich's initial hack is already enough to get the apps running as well (this one:http://bugs.winehq.org/attachment.cgi?id=13379)
That's fine. You can still add a test that does the same
as what the app does.
Hi, as there isn't really much activity in the bug (understatement haha) i tried to hack up a test myself. Rob, is the test below more or less what you meant? or am i way off...
Yes, almost exactly what I meant. Please see some minor comments below.
(The test passes on winxp, and fails in wine, so afaics shows we should support the interface )
diff --git a/dlls/ole32/tests/compobj.c b/dlls/ole32/tests/compobj.c index bdc34d9..49c3276 100644 --- a/dlls/ole32/tests/compobj.c +++ b/dlls/ole32/tests/compobj.c @@ -28,6 +28,7 @@ #include "objbase.h" #include "shlguid.h" #include "urlmon.h" /* for CLSID_FileProtocol */ +//#include "ctxtcall.h"
Please resend the patch adding the IDL file for this generated file and get it in before sending this patch adding the tests.
#include "wine/test.h"
@@ -61,6 +62,15 @@ static const IID IID_IWineTest = 0x4fd0, {0xa1, 0xa2, 0x5d, 0x5a, 0x36, 0x54, 0xd3, 0xbd} }; /* 5201163f-8164-4fd0-a1a2-5d5a3654d3bd */
+static const IID IID_IContextCallback = +{
- 0x000001da ,
- 0x0000,
- 0x0000,
- {0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46 }
+};
static const CLSID CLSID_WineOOPTest = { 0x5201163f, 0x8164, @@ -1022,6 +1032,26 @@ static void test_CoGetObjectContext(void) CoUninitialize(); }
+static void test_ContextCallBack(void) +{
- HRESULT hr;
- IComThreadingInfo *pComThreadingInfo;
- if (!pCoGetObjectContext)
- {
skip("CoGetObjectContext not present\n");
return;
- }
- pCoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
- hr = pCoGetObjectContext(&IID_IContextCallback, (void
**)&pComThreadingInfo);
On success you need to call IContextCallback_Release on the returned object to avoid a memory leak.
- ok_ole_success(hr, "CoGetObjectContext");
- CoUninitialize();
+}
START_TEST(compobj) { HMODULE hOle32 = GetModuleHandle("ole32");