[PATCH] make cygipc semaphores persistent

Charles Wilson cwilson@ece.gatech.edu
Fri Jun 20 05:32:00 GMT 2003


Joe Buehler wrote:

> The semaphores provided by the 1.14-1 version of cygipc are not 
> persistent -- once
> all client processes close a semaphore, it disappears.  This is 
> different than standard
> UNIX semantics, in which semaphores persist until removed or system 
> reboot.  The
> attached patch fixes this, providing the standard UNIX semantics for 
> semaphore lifetime.
> (Semaphores will persist until ipc-daemon is killed).
> 
> I would appreciate it if the owner(s) of cygipc review this patch and 
> roll it in
> to the "official" distribution if it looks OK.  The basic trick is that 
> the ipc-daemon
> process needs to keep an open handle for all semaphores in a non-removed 
> state.
> It looks as though there was code in cygipc that attempted this, but it 
> was removed in
> version 1.04.
> 
> I have included a couple typo fixes in the patch also.

This patch looks right to me, given the intent.  However, I'll have to 
take your word for standard 'persistence' behavior...

I'll incorporate this patch -- but I don't want to mess with cygipc-1.15 
right now.  Let's save this for cygipc-2.x, which should come out Real 
Soon after cygwin-1.5.0.  Which itself is due RSN.

--Chuck



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list