🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #9277

Re: mutex won't release

#9277
From: Remy Lebeau (TeamB)
Date: Wed, 21 Jul 2004 18:59
15 lines
1390 bytes
"Ad Lagendijk" <ad_lagendijk@yahoo.com_no_spam> wrote in message
news:40feb982$1@newsgroups.borland.com...

>     HANDLE hMutex = CreateMutex(NULL,true,"1");
>     ReleaseMutex(hMutex);  // hMutex does not seem to
>    become invalid after this

Releasing a mutex is not the same thing as freeing the mutex memory.
ReleaseMutex() simply gives up ownership of the mutex so that another
thread/process can gain ownership.  To actually free the resources that the
mutex uses, you have to use CloseHandle().


Gambit
Technical Details
Message-ID: <40febcc2$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <40feb982$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,ad55a220cec49a77,start
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <gambit47.no.spam@no.spam.yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <40feb982$1@newsgroups.borland.com>
Subject: Re: mutex won't release
Date: Wed, 21 Jul 2004 11:59:11 -0700
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <40febcc2$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1090436290 68.69.17.41 (21 Jul 2004 11:58:10 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail