mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
Disabled evaluation of strpos() with empty needle.
This commit is contained in:
parent
e8908946e5
commit
74a29468ef
@ -477,7 +477,10 @@ static inline int ct_eval_func_call(
|
||||
return SUCCESS;
|
||||
} else if (zend_string_equals_literal(name, "strpos")) {
|
||||
const char *found;
|
||||
if (num_args != 2 || Z_TYPE_P(args[0]) != IS_STRING || Z_TYPE_P(args[1]) != IS_STRING) {
|
||||
if (num_args != 2
|
||||
|| Z_TYPE_P(args[0]) != IS_STRING
|
||||
|| Z_TYPE_P(args[1]) != IS_STRING
|
||||
|| !Z_STRLEN_P(args[1])) {
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user