From 6262280ad4a15fa28f94cb29a583d2b1ba52aef0 Mon Sep 17 00:00:00 2001 From: David Hedbor Date: Wed, 24 Nov 1999 02:34:50 +0000 Subject: [PATCH] Don't create a new thread for each php-script - use the handler thread. --- sapi/roxen/phpmod.pike | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sapi/roxen/phpmod.pike b/sapi/roxen/phpmod.pike index 45341c34d0..1213e7f558 100644 --- a/sapi/roxen/phpmod.pike +++ b/sapi/roxen/phpmod.pike @@ -1,4 +1,4 @@ -/* Roxen PHP module based of the Roxen PHP module for Roxen 1.4. */ +/* Roxen PHP module based of the Roxen CGI module for Roxen 1.4. */ #include #include @@ -16,9 +16,10 @@ string trim( string what ) what = reverse(what); return what; } + //#define PHP_DEBUG #ifdef PHP_DEBUG -#define DWERROR(X) report_debug(X) +#define DWERROR(X) report_debug("Thr("+getpid()+"): "+X) #else /* !PHP_DEBUG */ #define DWERROR(X) #endif /* PHP_DEBUG */ @@ -157,7 +158,7 @@ class PHPScript mapping options = ([ "env":environment, ]); - thread_create(interpretor->run, command, options, this_object(), done); + interpretor->run(command, options, this_object(), done); mid->my_fd->set_close_callback(done); return this_object(); } -- 2.40.0