felipe          Thu May  8 16:58:44 2008 UTC

  Modified files:              
    /ZendEngine2        zend_API.c 
    /ZendEngine2/tests  bug31720.phpt 
    /php-src/ext/standard/tests/array   array_filter_variation2.phpt 
                                        array_map_variation17.phpt 
                                        array_walk_recursive_variation2.phpt 
                                        array_walk_variation2.phpt 
                                        uasort_variation2.phpt 
  Log:
  - Fixed detection of invalid class name
  
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_API.c?r1=1.469&r2=1.470&diff_format=u
Index: ZendEngine2/zend_API.c
diff -u ZendEngine2/zend_API.c:1.469 ZendEngine2/zend_API.c:1.470
--- ZendEngine2/zend_API.c:1.469        Thu May  8 15:39:35 2008
+++ ZendEngine2/zend_API.c      Thu May  8 16:58:43 2008
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_API.c,v 1.469 2008/05/08 15:39:35 felipe Exp $ */
+/* $Id: zend_API.c,v 1.470 2008/05/08 16:58:43 felipe Exp $ */
 
 #include "zend.h"
 #include "zend_execute.h"
@@ -3035,7 +3035,7 @@
                                        }
                                } else {
                                        if 
(zend_hash_num_elements(Z_ARRVAL_P(callable)) == 2) {
-                                               if (!obj) {
+                                               if (!obj || (Z_TYPE_PP(obj) != 
IS_OBJECT && Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_UNICODE)) {
                                                        if (error) 
zend_spprintf(error, 0, "first array member is not a valid class name or 
object");
                                                } else {
                                                        if (error) 
zend_spprintf(error, 0, "second array member is not a valid method");
http://cvs.php.net/viewvc.cgi/ZendEngine2/tests/bug31720.phpt?r1=1.5&r2=1.6&diff_format=u
Index: ZendEngine2/tests/bug31720.phpt
diff -u ZendEngine2/tests/bug31720.phpt:1.5 ZendEngine2/tests/bug31720.phpt:1.6
--- ZendEngine2/tests/bug31720.phpt:1.5 Mon Feb  4 14:29:51 2008
+++ ZendEngine2/tests/bug31720.phpt     Thu May  8 16:58:43 2008
@@ -10,5 +10,5 @@
 --EXPECTF--
 Notice: Undefined variable: nonesuchvar in %s on line %d
 
-Warning: array_walk() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_walk() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 ===DONE===
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/array_filter_variation2.phpt?r1=1.3&r2=1.4&diff_format=u
Index: php-src/ext/standard/tests/array/array_filter_variation2.phpt
diff -u php-src/ext/standard/tests/array/array_filter_variation2.phpt:1.3 
php-src/ext/standard/tests/array/array_filter_variation2.phpt:1.4
--- php-src/ext/standard/tests/array/array_filter_variation2.phpt:1.3   Mon Feb 
 4 15:22:08 2008
+++ php-src/ext/standard/tests/array/array_filter_variation2.phpt       Thu May 
 8 16:58:43 2008
@@ -134,7 +134,7 @@
 Warning: array_filter() expects parameter 2 to be a valid callback, array must 
have exactly two members in %s on line %d
 NULL
 -- Iteration 13 --
-Warning: array_filter() expects parameter 2 to be a valid callback, second 
array member is not a valid method in %s on line %d
+Warning: array_filter() expects parameter 2 to be a valid callback, first 
array member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 Warning: array_filter() expects parameter 2 to be a valid callback, first 
array member is not a valid class name or object in %s on line %d
@@ -221,7 +221,7 @@
 Warning: array_filter() expects parameter 2 to be a valid callback, array must 
have exactly two members in %s on line %d
 NULL
 -- Iteration 13 --
-Warning: array_filter() expects parameter 2 to be a valid callback, second 
array member is not a valid method in %s on line %d
+Warning: array_filter() expects parameter 2 to be a valid callback, first 
array member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 Warning: array_filter() expects parameter 2 to be a valid callback, first 
array member is not a valid class name or object in %s on line %d
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/array_map_variation17.phpt?r1=1.2&r2=1.3&diff_format=u
Index: php-src/ext/standard/tests/array/array_map_variation17.phpt
diff -u php-src/ext/standard/tests/array/array_map_variation17.phpt:1.2 
php-src/ext/standard/tests/array/array_map_variation17.phpt:1.3
--- php-src/ext/standard/tests/array/array_map_variation17.phpt:1.2     Mon Feb 
 4 12:37:15 2008
+++ php-src/ext/standard/tests/array/array_map_variation17.phpt Thu May  8 
16:58:43 2008
@@ -141,11 +141,11 @@
 NULL
 
 -- Iteration 17 --
-Warning: array_map() expects parameter 1 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_map() expects parameter 1 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
 -- Iteration 18 --
-Warning: array_map() expects parameter 1 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_map() expects parameter 1 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
 -- Iteration 19 --
@@ -224,11 +224,11 @@
 NULL
 
 -- Iteration 17 --
-Warning: array_map() expects parameter 1 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_map() expects parameter 1 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
 -- Iteration 18 --
-Warning: array_map() expects parameter 1 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_map() expects parameter 1 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
 -- Iteration 19 --
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt?r1=1.3&r2=1.4&diff_format=u
Index: php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt
diff -u 
php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt:1.3 
php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt:1.4
--- php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt:1.3   
Mon Feb  4 13:08:27 2008
+++ php-src/ext/standard/tests/array/array_walk_recursive_variation2.phpt       
Thu May  8 16:58:43 2008
@@ -179,10 +179,10 @@
 NULL
 -- Iteration 13 --
 
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
second array member is not a valid method in %s on line %d
+Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
first array member is not a valid class name or object in %s on line %d
 NULL
 
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
second array member is not a valid method in %s on line %d
+Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
first array member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
@@ -357,10 +357,10 @@
 NULL
 -- Iteration 13 --
 
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
second array member is not a valid method in %s on line %d
+Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
first array member is not a valid class name or object in %s on line %d
 NULL
 
-Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
second array member is not a valid method in %s on line %d
+Warning: array_walk_recursive() expects parameter 2 to be a valid callback, 
first array member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/array_walk_variation2.phpt?r1=1.3&r2=1.4&diff_format=u
Index: php-src/ext/standard/tests/array/array_walk_variation2.phpt
diff -u php-src/ext/standard/tests/array/array_walk_variation2.phpt:1.3 
php-src/ext/standard/tests/array/array_walk_variation2.phpt:1.4
--- php-src/ext/standard/tests/array/array_walk_variation2.phpt:1.3     Mon Feb 
 4 13:08:27 2008
+++ php-src/ext/standard/tests/array/array_walk_variation2.phpt Thu May  8 
16:58:43 2008
@@ -179,10 +179,10 @@
 NULL
 -- Iteration 13 --
 
-Warning: array_walk() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_walk() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
-Warning: array_walk() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_walk() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
@@ -357,10 +357,10 @@
 NULL
 -- Iteration 13 --
 
-Warning: array_walk() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_walk() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 
-Warning: array_walk() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: array_walk() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/uasort_variation2.phpt?r1=1.3&r2=1.4&diff_format=u
Index: php-src/ext/standard/tests/array/uasort_variation2.phpt
diff -u php-src/ext/standard/tests/array/uasort_variation2.phpt:1.3 
php-src/ext/standard/tests/array/uasort_variation2.phpt:1.4
--- php-src/ext/standard/tests/array/uasort_variation2.phpt:1.3 Mon Feb  4 
13:08:27 2008
+++ php-src/ext/standard/tests/array/uasort_variation2.phpt     Thu May  8 
16:58:43 2008
@@ -148,11 +148,11 @@
 NULL
 -- Iteration 13 --
 
-Warning: uasort() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: uasort() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
-Warning: uasort() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: uasort() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 15 --
 
@@ -263,11 +263,11 @@
 NULL
 -- Iteration 13 --
 
-Warning: uasort() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: uasort() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 14 --
 
-Warning: uasort() expects parameter 2 to be a valid callback, second array 
member is not a valid method in %s on line %d
+Warning: uasort() expects parameter 2 to be a valid callback, first array 
member is not a valid class name or object in %s on line %d
 NULL
 -- Iteration 15 --
 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to