PHP 4.0 Bug #10400 Updated: output_transform_file pointer in sablot.c MUST be initialized to NULL in php_sab

From: Date: Thu, 19 Apr 2001 14:35:14 +0000
Subject: PHP 4.0 Bug #10400 Updated: output_transform_file pointer in sablot.c MUST be initialized to NULL in php_sab
Groups: php.dev 
Request: Send a blank email to php-dev+get-51980@lists.php.net to get a copy of this message
ID: 10400 User Update by: lsorense@csclub.uwaterloo.ca Status: Open Bug Type: Sablotron XSL Description: output_transform_file pointer in sablot.c MUST be initialized to NULL in php_sab The two suggested changes fixes the segfaults in apache and the hangs that occour when using xslt_output_begintransform. The hang/segfault occours after each available apache thread has served one request, hence the reson it's seen after 10 to 15 quick reloads, since that's usually how many idle apache threads people have running. Here is a complete patch for sablot.c: diff -ur php4-4.0.4.5rc6/ext/sablot/sablot.c php4-4.0.4.5rc6.fixed/ext/sablot/sablot.c --- php4-4.0.4.5rc6/ext/sablot/sablot.c Sat Mar 3 20:09:36 2001 +++ php4-4.0.4.5rc6.fixed/ext/sablot/sablot.c Thu Apr 19 08:44:21 2001 @@ -70,7 +70,7 @@ /* Macro's */ /* Free macros */ -#define S_FREE(__var) if (__var) efree(__var); +#define S_FREE(__var) if (__var) {efree(__var);__var = NULL;} #define FUNCH_FREE(__var) if (__var) zval_ptr_dtor(&(__var)); /* ERROR Macros */ @@ -211,6 +211,7 @@ SABLOTG(processor) = NULL; SABLOTG(errors) = NULL; SABLOTG(errorHandler) = NULL; + SABLOTG(output_transform_file) = NULL; } Previous Comments: --------------------------------------------------------------------------- [2001-04-19 09:01:13] lsorense@csclub.uwaterloo.ca --------------------------------------------------------------------------- Full Bug description available at: http://bugs.php.net/?id=10400

« previous php.dev (#51980) next »