]> granicus.if.org Git - php/commitdiff
@- Made in_array() and search_array() allow the needle to be an array in
authorAndrei Zmievski <andrei@php.net>
Fri, 31 Aug 2001 04:52:10 +0000 (04:52 +0000)
committerAndrei Zmievski <andrei@php.net>
Fri, 31 Aug 2001 04:52:10 +0000 (04:52 +0000)
@  itself. (Andrei)

ext/standard/array.c

index 72ccc5eeeeab4f8e4f2f7235d230a0a61c56da41..83942db40931c81f2fbd927018057f6f6ad9780d 100644 (file)
@@ -1048,7 +1048,7 @@ static void php_search_array(INTERNAL_FUNCTION_PARAMETERS, int behavior)
                WRONG_PARAM_COUNT;
        }
        
-       if (Z_TYPE_PP(value) == IS_ARRAY || Z_TYPE_PP(value) == IS_OBJECT) {
+       if (Z_TYPE_PP(value) == IS_OBJECT) {
                php_error(E_WARNING, "Wrong datatype for first argument in call to %s", get_active_function_name(TSRMLS_C));
                RETURN_FALSE;
        }