[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Another Semaphore question.
- To: Linux-IL Mailing list <linux-il(at-nospam)cs.huji.ac.il>
- Subject: Re: Another Semaphore question.
- From: oron(at-nospam)actcom.co.il
- Date: Fri, 04 May 2001 09:18:13 +0300 (IDT)
- In-Reply-To: <Pine.LNX.4.30.0105031752460.5438-100000@frodo.sharat.co.il>
- Sender: oron(at-nospam)actcom.co.il
- Sender: linux-il-bounce(at-nospam)cs.huji.ac.il
On 03-May-2001 Stanislav Malyshev a.k.a Frodo wrote:
> OA>> and then leave it lying around and exit the process - will it stay
> OA>> in the system when no current process uses it ?
>
> Yes. This is one of the problems with semaphores. BTW, why not using
This is not a PROBLEM but a FEATURE. All Sys-V IPC (semaphores,
message queues, shared memory) outlive their creators.
You are completely right that if this behavior isn't desired in the
application, we should choose other IPC mechanism (that's why we have so
many of them).
However, semaphore aren't being used just for Mutual-Exclusion problems.
A classical counter example is producer-consumer that aren't running
continuously.
------------------------------------------------
Oron Peled Voice/Fax: +972-4-8228492
oron@actcom.co.il http://www.actcom.co.il/~oron
There's nothing wrong with Windows 2000...
...that Linux can't fix
=================================================================
To unsubscribe, send mail to linux-il-request@linux.org.il with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail linux-il-request@linux.org.il