Jan Zerebecki : ole32: Add DebugInfo to critical sections.
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Mar 12 08:28:55 CDT 2007
Module: wine
Branch: master
Commit: 0f7a3811b4cdf818c04e5debd89390522410b43d
URL: http://source.winehq.org/git/wine.git/?a=commit;h=0f7a3811b4cdf818c04e5debd89390522410b43d
Author: Jan Zerebecki <jan.wine at zerebecki.de>
Date: Sun Mar 11 00:21:23 2007 +0100
ole32: Add DebugInfo to critical sections.
Also add missing DeleteCriticalSection.
---
dlls/ole32/moniker.c | 4 ++++
dlls/ole32/stg_prop.c | 3 +++
2 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/dlls/ole32/moniker.c b/dlls/ole32/moniker.c
index c899918..0cb35fa 100644
--- a/dlls/ole32/moniker.c
+++ b/dlls/ole32/moniker.c
@@ -279,6 +279,9 @@ RunningObjectTableImpl_Destroy(void)
rot_entry_delete(rot_entry);
}
+ DEBUG_CLEAR_CRITSEC_NAME(&runningObjectTableInstance->lock);
+ DeleteCriticalSection(&runningObjectTableInstance->lock);
+
/* free the ROT structure memory */
HeapFree(GetProcessHeap(),0,runningObjectTableInstance);
runningObjectTableInstance = NULL;
@@ -824,6 +827,7 @@ HRESULT WINAPI RunningObjectTableImpl_Initialize(void)
list_init(&runningObjectTableInstance->rot);
InitializeCriticalSection(&runningObjectTableInstance->lock);
+ DEBUG_SET_CRITSEC_NAME(&runningObjectTableInstance->lock, "RunningObjectTableImpl.lock");
return S_OK;
}
diff --git a/dlls/ole32/stg_prop.c b/dlls/ole32/stg_prop.c
index a4be7b7..45c760e 100644
--- a/dlls/ole32/stg_prop.c
+++ b/dlls/ole32/stg_prop.c
@@ -233,6 +233,7 @@ static ULONG WINAPI IPropertyStorage_fnRelease(
if (This->dirty)
IPropertyStorage_Commit(iface, STGC_DEFAULT);
IStream_Release(This->stm);
+ This->cs.DebugInfo->Spare[0] = 0;
DeleteCriticalSection(&This->cs);
PropertyStorage_DestroyDictionaries(This);
HeapFree(GetProcessHeap(), 0, This);
@@ -1978,6 +1979,7 @@ static HRESULT PropertyStorage_BaseConstruct(IStream *stm,
(*pps)->vtbl = &IPropertyStorage_Vtbl;
(*pps)->ref = 1;
InitializeCriticalSection(&(*pps)->cs);
+ (*pps)->cs.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": PropertyStorage_impl.cs");
(*pps)->stm = stm;
memcpy(&(*pps)->fmtid, rfmtid, sizeof((*pps)->fmtid));
(*pps)->grfMode = grfMode;
@@ -1986,6 +1988,7 @@ static HRESULT PropertyStorage_BaseConstruct(IStream *stm,
if (FAILED(hr))
{
IStream_Release(stm);
+ (*pps)->cs.DebugInfo->Spare[0] = 0;
DeleteCriticalSection(&(*pps)->cs);
HeapFree(GetProcessHeap(), 0, *pps);
*pps = NULL;
More information about the wine-cvs
mailing list