Bugfix: second RegOpenKey should use CLSIDkey instead of HKEY_CLASSES_ROOT.

This commit is contained in:
Marcus Meissner 1998-11-30 10:33:17 +00:00 committed by Alexandre Julliard
parent 8d01e080b9
commit 6dd19961c5
1 changed files with 4 additions and 2 deletions

View File

@ -764,8 +764,7 @@ HRESULT WINAPI CoGetClassObject(REFCLSID rclsid, DWORD dwClsContext,
if (hres != ERROR_SUCCESS)
return REGDB_E_READREGDB;
hres = RegOpenKeyEx32A(HKEY_CLASSES_ROOT,xclsid,0,KEY_QUERY_VALUE,
&key);
hres = RegOpenKeyEx32A(CLSIDkey,xclsid,0,KEY_QUERY_VALUE,&key);
if (hres != ERROR_SUCCESS) {
RegCloseKey(CLSIDkey);
return REGDB_E_CLASSNOTREG;
@ -789,6 +788,9 @@ HRESULT WINAPI CoGetClassObject(REFCLSID rclsid, DWORD dwClsContext,
TRACE(ole,"couldn't find function DllGetClassObject in %s\n", dllName);
return E_ACCESSDENIED;
}
/* FIXME: Shouldn't we get a classfactory and use this to create
* the required object?
*/
return DllGetClassObject(rclsid, iid, ppv);
}
return hres;