Bug #16986 Updated: semaphore autorelease can be a bug....
| From: | wez@php.net | Date: | Fri, 03 May 2002 10:47:10 +0000 |
| Subject: | Bug #16986 Updated: semaphore autorelease can be a bug.... | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-6824@lists.php.net to get a copy of this message | ||
ID: 16986
Updated by: wez@php.net
Reported By: AlberT@SuperAlberT.it
-Status: Open
+Status: Feedback
Bug Type: Semaphore related
Operating System: Linux 2.4.18
PHP Version: 4.1.2
New Comment:
But a process that acquires a semaphore and then exits will
case deadlocks, because no one else can acquire the semaphore??
Can you give a good example of where leaving the semaphore acquired is
actually useful?
Previous Comments:
------------------------------------------------------------------------
[2002-05-03 05:37:33] AlberT@SuperAlberT.it
sem_acquire() function has this behavior:
After processing a request, any semaphores acquired by the process but
not explicitly released will be released automatically and a warning
will be generated.
This is not a great thing, infact in this way the readers/writers
classical IPC problem, with writers precedence is impossible to
implement !!!
I think an option to disable autorelease is usefull.
(I sent a feature/change request, but I had no feadback :-( )
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=16986&edit=1