Re: cvs: php4 /ext/standard var.c

From: Date: Thu, 03 Oct 2002 09:02:50 +0000
Subject: Re: cvs: php4 /ext/standard var.c
References: 1  Groups: php.cvs 
Request: Send a blank email to php-cvs+get-14451@lists.php.net to get a copy of this message
On Thu, 3 Oct 2002, Yasuo Ohgaki wrote: > yohgaki Thu Oct 3 04:54:45 2002 EDT > > Modified files: > /php4/ext/standard var.c > Log: > Prevent unwanted fluhsing. Please don't add more hacks, but fix it right. You broke behavior, please revert that. Derick > > > Index: php4/ext/standard/var.c > diff -u php4/ext/standard/var.c:1.145 php4/ext/standard/var.c:1.146 > --- php4/ext/standard/var.c:1.145 Wed Jun 26 03:36:01 2002 > +++ php4/ext/standard/var.c Thu Oct 3 04:54:45 2002 > @@ -342,21 +342,23 @@ > PHP_FUNCTION(var_export) > { > zval *var; > - zend_bool i = 0; > + zend_bool return_output = 0; > > - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|b", &var, &i) == > FAILURE) { > + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|b", &var, > &return_output) == FAILURE) { > return; > } > > - if (i) { > + if (return_output) { > + php_output_set_status(0 TSRMLS_CC); > php_start_ob_buffer (NULL, 0, 1 TSRMLS_CC); > } > > php_var_export(&var, 1 TSRMLS_CC); > > - if (i) { > + if (return_output) { > php_ob_get_buffer (return_value TSRMLS_CC); > php_end_ob_buffer (0, 0 TSRMLS_CC); > + php_output_set_status(1 TSRMLS_CC); > } > } > /* }}} */ > > > > -- > PHP CVS Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- --------------------------------------------------------------------------- Derick Rethans http://derickrethans.nl/ JDI Media Solutions --------------[ if you hold a unix shell to your ear, do you hear the c? ]-

« previous php.cvs (#14451) next »