Re: thread safety for binding issues
| From: | Shane Caraveo | Date: | Fri, 29 Mar 2002 17:48:31 +0000 |
| Subject: | Re: thread safety for binding issues | ||
| References: | 1 2 3 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-81937@lists.php.net to get a copy of this message | ||
Markus Fischer wrote:
On Fri, Mar 29, 2002 at 09:14:46AM -0800, Shane Caraveo wrote :You'll probably be able to get away with using condition variables, but it's too much to describe, and I haven't done much pthreads stuff. You could get the o'reilly pthreads book for reference, or dig around for exampls on the net. ShaneMarkus Fischer wrote:Hi, how much thread-safe is PHP on linux when compiled with --enable-experimental-zts ? When I a set up a callback handler for a 3rd library which uses threads and in this (C) callback I call call_user_function() (to provide custom callbacks) -> bang , I get a segfault. Should it work and I'm doing something stupid or is this some limitation? Hints? - MarkusPHP is thread safe, not multi-threaded. ie. scripts cannot be multi-threaded. You will have to somehow proxy the data back to the original calling thread for your library to work.Ah, understood. So, the short answer would be it was by own stupidity ;-)About proxying the data .. you don't happen to have some more description or resource how to accomplish this before I try to reinvent the wheel ? thanks.- Markus