]> granicus.if.org Git - php/commitdiff
- fix tests to comply with upgraded string.c
authorMichael Wallner <mike@php.net>
Tue, 22 Aug 2006 08:16:37 +0000 (08:16 +0000)
committerMichael Wallner <mike@php.net>
Tue, 22 Aug 2006 08:16:37 +0000 (08:16 +0000)
- use add_next_index_zval() when listing handlers

main/output.c
tests/output/ob_014.phpt
tests/output/ob_015.phpt

index e8916ee68f067f902b90f26978d62a14c903d6d1..9dddb645830fe363ec4ee448278f97252fa60cdc 100644 (file)
@@ -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;
 }
 /* }}} */
index 696c91a03aa89bc43e0589ff2c7d8a94822668a3..03980c2dd91a2628f5f528841c07e5db6ec20461 100644 (file)
@@ -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
index 53d3acd1443b0851ea12883d8499073f60c5534f..6454fcd2e59d42b25fe24d971004ddd45e3f2da9 100644 (file)
@@ -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