cvs: ZendEngine2(PHP_5_2) / zend_execute_API.c php-src NEWS
| From: | Dmitry Stogov | Date: | Fri, 10 Nov 2006 11:49:36 +0000 |
| Subject: | cvs: ZendEngine2(PHP_5_2) / zend_execute_API.c php-src NEWS | ||
| Groups: | php.zend-engine.cvs | ||
| Request: | Send a blank email to php-zend-engine-cvs+get-5379@lists.php.net to get a copy of this message | ||
dmitry Fri Nov 10 11:49:36 2006 UTC
Modified files: (Branch: PHP_5_2)
/php-src NEWS
/ZendEngine2 zend_execute_API.c
Log:
Start timiout thread on Windows only if necessary
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.348&r2=1.2027.2.547.2.349&diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.348 php-src/NEWS:1.2027.2.547.2.349
--- php-src/NEWS:1.2027.2.547.2.348 Fri Nov 10 11:42:07 2006
+++ php-src/NEWS Fri Nov 10 11:49:35 2006
@@ -8,6 +8,7 @@
. implemented registry cache that prevent registry lookup on each request.
In case of modification of corresponding registry-tree PHP will reload
it automatic
+ . start timiout thread only if necessary
- Zend Memory Manager Improvements (Dmitry)
. use HeapAlloc() instead of VirtualAlloc()
. use "win32" storage manager (instead of "malloc") on Windows by default
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_execute_API.c?r1=1.331.2.20.2.10&r2=1.331.2.20.2.11&diff_format=u
Index: ZendEngine2/zend_execute_API.c
diff -u ZendEngine2/zend_execute_API.c:1.331.2.20.2.10
ZendEngine2/zend_execute_API.c:1.331.2.20.2.11
--- ZendEngine2/zend_execute_API.c:1.331.2.20.2.10 Wed Oct 18 17:04:49 2006
+++ ZendEngine2/zend_execute_API.c Fri Nov 10 11:49:35 2006
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_execute_API.c,v 1.331.2.20.2.10 2006/10/18 17:04:49 johannes Exp $ */
+/* $Id: zend_execute_API.c,v 1.331.2.20.2.11 2006/11/10 11:49:35 dmitry Exp $ */
#include <stdio.h>
#include <signal.h>
@@ -1381,6 +1381,9 @@
TSRMLS_FETCH();
EG(timeout_seconds) = seconds;
+ if(!seconds) {
+ return;
+ }
#ifdef ZEND_WIN32
if (timeout_thread_initialized==0 &&
InterlockedIncrement(&timeout_thread_initialized)==1) {
/* We start up this process-wide thread here and not in zend_startup(), because if Zend
@@ -1419,7 +1422,9 @@
void zend_unset_timeout(TSRMLS_D)
{
#ifdef ZEND_WIN32
- PostThreadMessage(timeout_thread_id, WM_UNREGISTER_ZEND_TIMEOUT, (WPARAM) GetCurrentThreadId(),
(LPARAM) 0);
+ if(timeout_thread_initialized) {
+ PostThreadMessage(timeout_thread_id, WM_UNREGISTER_ZEND_TIMEOUT, (WPARAM) GetCurrentThreadId(),
(LPARAM) 0);
+ }
#else
# ifdef HAVE_SETITIMER
{