Module: wine Branch: master Commit: a2d59ef534b93c0eb85825c7541ea4380f9528a0 URL: http://source.winehq.org/git/wine.git/?a=commit;h=a2d59ef534b93c0eb85825c754...
Author: Rob Shearman rob@codeweavers.com Date: Fri Dec 1 15:01:27 2006 +0000
ole32: Implement DataCache_GetClassID.
---
dlls/ole32/datacache.c | 16 +++++++++++++++- 1 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/dlls/ole32/datacache.c b/dlls/ole32/datacache.c index 378b86e..508b9fc 100644 --- a/dlls/ole32/datacache.c +++ b/dlls/ole32/datacache.c @@ -953,8 +953,22 @@ static HRESULT WINAPI DataCache_GetClass IPersistStorage* iface, CLSID* pClassID) { + DataCache *This = impl_from_IPersistStorage(iface); + HRESULT hr = S_OK; + TRACE("(%p, %p)\n", iface, pClassID); - return E_NOTIMPL; + + if (This->presentationStorage != NULL) + { + STATSTG statstg; + hr = IStorage_Stat(This->presentationStorage, &statstg, STATFLAG_NONAME); + if (SUCCEEDED(hr)) + memcpy(pClassID, &statstg.clsid, sizeof(*pClassID)); + } + else + memcpy(pClassID, &CLSID_NULL, sizeof(*pClassID)); + + return hr; }
/************************************************************************