mike Wed Aug 9 10:21:10 2006 UTC
Modified files:
/php-src/main output.c
Log:
- use HashPosition for traversal of registered reverse conflicts
- fix protos
http://cvs.php.net/viewvc.cgi/php-src/main/output.c?r1=1.184&r2=1.185&diff_format=u
Index: php-src/main/output.c
diff -u php-src/main/output.c:1.184 php-src/main/output.c:1.185
--- php-src/main/output.c:1.184 Tue Aug 8 16:59:11 2006
+++ php-src/main/output.c Wed Aug 9 10:21:10 2006
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: output.c,v 1.184 2006/08/08 16:59:11 tony2001 Exp $ */
+/* $Id: output.c,v 1.185 2006/08/09 10:21:10 mike Exp $ */
#ifndef PHP_OUTPUT_DEBUG
# define PHP_OUTPUT_DEBUG 0
@@ -524,6 +524,7 @@
Starts the set up output handler and pushes it on top of the stack.
Checks for any conflicts regarding the output handler to start */
PHPAPI int php_output_handler_start(php_output_handler *handler TSRMLS_DC)
{
+ HashPosition pos;
HashTable *rconflicts;
php_output_handler_conflict_check_t *conflict;
@@ -536,9 +537,9 @@
}
}
if (SUCCESS == zend_u_hash_find(&php_output_handler_reverse_conflicts,
Z_TYPE_P(handler->name), Z_UNIVAL_P(handler->name), Z_UNILEN_P(handler->name),
(void *) &rconflicts)) {
- for ( zend_hash_internal_pointer_reset(rconflicts);
- zend_hash_get_current_data(rconflicts, (void *)
&conflict) == SUCCESS;
- zend_hash_move_forward(rconflicts)) {
+ for ( zend_hash_internal_pointer_reset_ex(rconflicts, &pos);
+ zend_hash_get_current_data_ex(rconflicts, (void
*) &conflict, &pos) == SUCCESS;
+ zend_hash_move_forward_ex(rconflicts, &pos)) {
if (SUCCESS != (*conflict)(handler->name TSRMLS_CC)) {
return FAILURE;
}
@@ -1208,7 +1209,7 @@
}
/* }}} */
-/* {{{ static SUCCESS|FAILURE php_output_handler_compat_func(void *ctx, int
op, const char *in, size_t in_len, char **out, size_t *out_len TSRMLS_DC)
+/* {{{ static SUCCESS|FAILURE php_output_handler_compat_func(void *ctx,
php_output_context *)
php_output_handler_context_func_t for php_output_handler_func_t output
handlers */
static int php_output_handler_compat_func(void **handler_context,
php_output_context *output_context)
{
@@ -1224,7 +1225,7 @@
}
/* }}} */
-/* {{{ static SUCCESS|FAILURE php_output_handler_default_func(void *ctx, int
op, const char *in, size_t in_len, char **out, size_t *out_len TSRMLS_DC)
+/* {{{ static SUCCESS|FAILURE php_output_handler_default_func(void *ctx,
php_output_context *)
Default output handler */
static int php_output_handler_default_func(void **handler_context,
php_output_context *output_context)
{
@@ -1238,7 +1239,7 @@
}
/* }}} */
-/* {{{ static SUCCESS|FAILURE php_output_handler_devnull_func(void *ctx, int
op, const char *in, size_t in_len, char **out, size_t *out_len TSRMLS_DC)
+/* {{{ static SUCCESS|FAILURE php_output_handler_devnull_func(void *ctx,
php_output_context *)
Null output handler */
static int php_output_handler_devnull_func(void **handler_context,
php_output_context *output_context)
{
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php