Don't fail in CoRegisterClassObject if the class already exists and
the REGCLS_MULTIPLEUSE flag is specified.
This commit is contained in:
parent
625f5862a5
commit
044ccc40f3
|
@ -1389,7 +1389,14 @@ HRESULT WINAPI CoRegisterClassObject(
|
|||
*/
|
||||
hr = COM_GetRegisteredClassObject(rclsid, dwClsContext, &foundObject);
|
||||
if (hr == S_OK) {
|
||||
if (flags & REGCLS_MULTIPLEUSE) {
|
||||
if (dwClsContext & CLSCTX_LOCAL_SERVER)
|
||||
hr = CoLockObjectExternal(foundObject, TRUE, FALSE);
|
||||
IUnknown_Release(foundObject);
|
||||
return hr;
|
||||
}
|
||||
IUnknown_Release(foundObject);
|
||||
ERR("object already registered for class %s\n", debugstr_guid(rclsid));
|
||||
return CO_E_OBJISREG;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue