From 51ab24dd66ed4b2f46078b6422615c67228852a6 Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Mon, 14 Nov 2011 15:08:39 +0100 Subject: [PATCH] browseui: Give a name and delete the critical sections. --- dlls/browseui/compcatcachedaemon.c | 2 ++ dlls/browseui/progressdlg.c | 3 +++ 2 files changed, 5 insertions(+) diff --git a/dlls/browseui/compcatcachedaemon.c b/dlls/browseui/compcatcachedaemon.c index f480d355aa3..0acb4ec3d7f 100644 --- a/dlls/browseui/compcatcachedaemon.c +++ b/dlls/browseui/compcatcachedaemon.c @@ -57,6 +57,7 @@ static inline CompCatCacheDaemon *impl_from_IRunnableTask(IRunnableTask *iface) static void CompCatCacheDaemon_Destructor(CompCatCacheDaemon *This) { TRACE("destroying %p\n", This); + This->cs.DebugInfo->Spare[0] = 0; DeleteCriticalSection(&This->cs); heap_free(This); BROWSEUI_refCount--; @@ -154,6 +155,7 @@ HRESULT CompCatCacheDaemon_Constructor(IUnknown *pUnkOuter, IUnknown **ppOut) This->IRunnableTask_iface.lpVtbl = &CompCatCacheDaemonVtbl; This->refCount = 1; InitializeCriticalSection(&This->cs); + This->cs.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": CompCatCacheDaemon.cs"); TRACE("returning %p\n", This); *ppOut = (IUnknown *)This; diff --git a/dlls/browseui/progressdlg.c b/dlls/browseui/progressdlg.c index 11ebb7b4410..2de858c3333 100644 --- a/dlls/browseui/progressdlg.c +++ b/dlls/browseui/progressdlg.c @@ -260,6 +260,8 @@ static void ProgressDialog_Destructor(ProgressDialog *This) heap_free(This->cancelMsg); heap_free(This->title); heap_free(This); + This->cs.DebugInfo->Spare[0] = 0; + DeleteCriticalSection(&This->cs); BROWSEUI_refCount--; } @@ -503,6 +505,7 @@ HRESULT ProgressDialog_Constructor(IUnknown *pUnkOuter, IUnknown **ppOut) This->IProgressDialog_iface.lpVtbl = &ProgressDialogVtbl; This->refCount = 1; InitializeCriticalSection(&This->cs); + This->cs.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": ProgressDialog.cs"); TRACE("returning %p\n", This); *ppOut = (IUnknown *)This; -- 2.11.4.GIT