28 ok(
hr ==
S_OK,
"SHCreateDefClassObject failed: %08lx\n",
hr);
29 ok(pcf !=
NULL,
"pcf is NULL\n");
32 skip(
"pcf is NULL, skipping LockServer tests\n");
36 ok(refDll == 1,
"Expected refDll == 1 after init, got %ld\n", refDll);
39 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
40 ok(refDll == 2,
"Expected refDll == 2 after lock, got %ld\n", refDll);
43 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
44 ok(refDll == 1,
"Expected refDll == 1 after unlock, got %ld\n", refDll);
47 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
48 ok(refDll >= 0,
"refDll went negative after unlock when not locked: %ld\n", refDll);
51 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
53 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
55 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
57 ok(
hr ==
S_OK,
"LockServer() failed: %08lx\n",
hr);
60 ok(refDll == 0,
"Expected refDll == 0 after Release, got %ld\n", refDll);
static void test_LockServer(void)
static HRESULT CALLBACK CreateInstanceStub(IUnknown *pUnkOuter, REFIID riid, LPVOID *ppv)
const GUID IID_IClassFactory
HRESULT LockServer([in] BOOL fLock)
HRESULT WINAPI SHCreateDefClassObject(REFIID riid, LPVOID *ppv, LPFNCREATEINSTANCE lpfnCI, LPDWORD pcRefDll, REFIID riidInst)