Francois Gouget : services: Give a name to the scmdatabase critical section .

Alexandre Julliard julliard at winehq.org
Thu Oct 27 13:30:12 CDT 2011


Module: wine
Branch: master
Commit: 97ab9cc7e537a0a042b3f128fcfefb0021f49924
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=97ab9cc7e537a0a042b3f128fcfefb0021f49924

Author: Francois Gouget <fgouget at codeweavers.com>
Date:   Thu Oct 27 12:36:16 2011 +0200

services: Give a name to the scmdatabase critical section.

---

 programs/services/services.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/programs/services/services.c b/programs/services/services.c
index 2aa3683..7134ae7 100644
--- a/programs/services/services.c
+++ b/programs/services/services.c
@@ -405,6 +405,7 @@ static DWORD scmdatabase_create(struct scmdatabase **db)
     list_init(&(*db)->services);
 
     InitializeCriticalSection(&(*db)->cs);
+    (*db)->cs.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": scmdatabase");
 
     err = RegCreateKeyExW(HKEY_LOCAL_MACHINE, SZ_SERVICES_KEY, 0, NULL,
                           REG_OPTION_NON_VOLATILE, MAXIMUM_ALLOWED, NULL,
@@ -418,6 +419,7 @@ static DWORD scmdatabase_create(struct scmdatabase **db)
 static void scmdatabase_destroy(struct scmdatabase *db)
 {
     RegCloseKey(db->root_key);
+    db->cs.DebugInfo->Spare[0] = 0;
     DeleteCriticalSection(&db->cs);
     HeapFree(GetProcessHeap(), 0, db);
 }




More information about the wine-cvs mailing list