Re: SV: [PHP4BETA] php 4 smp problem

From: Date: Tue, 04 Jan 2000 00:48:36 +0000
Subject: Re: SV: [PHP4BETA] php 4 smp problem
References: 1 2  Groups: php.version4 
Request: Send a blank email to php-version4+get-8878@lists.php.net to get a copy of this message
> I'll be anticipating Saschas response for a few more days. I have no idea > what to do, maybe it's time to involve som Apache developer and/or SMP > kernel people? Our code has at least one problem. It calls php_error() from a signal handler. This function is definitively not reentrant (i.e. it manipulates hashes without locking etc. The obvious worst-case is that SIGPROF is delivered to the process while it is already in php_error()). So, please try the attached patch. -- Regards, Sascha Schumann Consultant

Index: main.c =================================================================== RCS file: /repository/php4/main.c,v retrieving revision 1.170 diff -u -r1.170 main.c --- main.c 2000/01/01 01:31:27 1.170 +++ main.c 2000/01/04 00:45:29 @@ -476,8 +476,10 @@ PLS_FETCH(); PG(connection_status) |= PHP_CONNECTION_TIMEOUT; +#ifdef PHP_ERROR_REENTRANT php_error(E_ERROR, "Maximum execution time of %d second%s exceeded", php_timeout_seconds, php_timeout_seconds == 1 ? "" : "s"); +#endif } #endif
« previous php.version4 (#8878) next »