🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Wait for "signal" from another application and/or thread

#8991
From: Eugene Mayevski [SecureBlackbox]
Date: Sat, 14 Aug 2004 21:49
22 lines
1916 bytes
Bob Gonder wrote:

> Did I read this wrong?

No, that was eclipse of my mind. My appologies to you and OP.

> Ahh, perhaps you were recommending Named Semaphores so that all
> threads in all instances of the program could all release with a
> single call?

Yes. One could use 2 semaphores -- one semaphore which is released by 
"client" threads that start waiting for main semaphore. And another -- 
main semaphore. Then the logic of signalling thread is (pseudocode)

while WaitFor(CountSem) = true do
   Signal(FlagSem);

-- 
Eugene Mayevski
EldoS Corp., CTO
Networking and security solutions, development and consulting services
http://www.eldos.com
Technical Details
Message-ID: <411e88f3$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!logbridge.uoregon.edu!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <4105617c$1@newsgroups.borland.com> <4105777f$3@newsgroups.borland.com> <411ccf89@newsgroups.borland.com> <gnsph0pq4c8mfhapah6cideqmbp6gqor5r@4ax.com> <411d2245@newsgroups.borland.com> <pboqh013avflntd8vgj1vcbrg000u94vb7@4ax.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,b6552239fe09c315
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Sun, 15 Aug 2004 00:49:30 +0300
From: "Eugene Mayevski [SecureBlackbox]" <mayevski@eldos.org>
Organization: EldoS Corporation
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624
X-Accept-Language: en-us, ru, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: Wait for "signal" from another application and/or thread 
References: <4105617c$1@newsgroups.borland.com> <4105777f$3@newsgroups.borland.com> <411ccf89@newsgroups.borland.com> <gnsph0pq4c8mfhapah6cideqmbp6gqor5r@4ax.com> <411d2245@newsgroups.borland.com> <pboqh013avflntd8vgj1vcbrg000u94vb7@4ax.com>
In-Reply-To: <pboqh013avflntd8vgj1vcbrg000u94vb7@4ax.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 82.144.222.199
Message-ID: <411e88f3$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1092520179 82.144.222.199 (14 Aug 2004 14:49:39 -0700)
Lines: 23
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!logbridge.uoregon.edu!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail