From 0ff7bc29d968facd4255dae83d2057d47c691a2b Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Tue, 22 Aug 2006 08:16:37 +0000 Subject: [PATCH] - fix tests to comply with upgraded string.c - use add_next_index_zval() when listing handlers --- main/output.c | 7 ++----- tests/output/ob_014.phpt | 2 +- tests/output/ob_015.phpt | 2 +- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/main/output.c b/main/output.c index e8916ee68f..9dddb64583 100644 --- a/main/output.c +++ b/main/output.c @@ -1131,11 +1131,8 @@ static int php_output_stack_apply_list(void *h, void *z) php_output_handler *handler = *(php_output_handler **) h; zval *array = (zval *) z; - if (Z_TYPE_P(handler->name) == IS_UNICODE) { - add_next_index_unicodel(array, Z_USTRVAL_P(handler->name), Z_USTRLEN_P(handler->name), 1); - } else { - add_next_index_stringl(array, Z_STRVAL_P(handler->name), Z_STRLEN_P(handler->name), 1); - } + ZVAL_ADDREF(handler->name); + add_next_index_zval(array, handler->name); return 0; } /* }}} */ diff --git a/tests/output/ob_014.phpt b/tests/output/ob_014.phpt index 696c91a03a..03980c2dd9 100644 --- a/tests/output/ob_014.phpt +++ b/tests/output/ob_014.phpt @@ -11,4 +11,4 @@ echo "foo\n"; --EXPECTF-- foo -Warning: Wrong parameter count for (null)() in %s on line %d +Warning: (null)() expects exactly 1 parameter, 2 given in %s on line %d diff --git a/tests/output/ob_015.phpt b/tests/output/ob_015.phpt index 53d3acd144..6454fcd2e5 100644 --- a/tests/output/ob_015.phpt +++ b/tests/output/ob_015.phpt @@ -8,4 +8,4 @@ echo "foo\n"; --EXPECTF-- foo -Warning: Wrong parameter count for str_rot13() in %s on line %d +Warning: str_rot13() expects exactly 1 parameter, 2 given in %s on line %d -- 2.40.0