diff options
author | Anatol Belski <ab@php.net> | 2015-11-12 09:28:10 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2015-11-12 09:28:10 +0100 |
commit | 9c4fd367835fac9dc4981bb1e8e8f6e7a612ecae (patch) | |
tree | dbcc6eccd54c665047444b5a3464fa14988c9c9e /Zend/tests/bug70898.phpt | |
parent | c2de445f79eb0be77d8b9eb349aab2a8e306d45c (diff) | |
download | php-git-9c4fd367835fac9dc4981bb1e8e8f6e7a612ecae.tar.gz |
add test for bug #70898
Diffstat (limited to 'Zend/tests/bug70898.phpt')
-rw-r--r-- | Zend/tests/bug70898.phpt | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/Zend/tests/bug70898.phpt b/Zend/tests/bug70898.phpt new file mode 100644 index 0000000000..6308ddc742 --- /dev/null +++ b/Zend/tests/bug70898.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #70895 null ptr deref and segfault with crafted calable +--FILE-- +<?php + function m($f,$a){ + return array_map($f,0); + } + + echo implode(m("",m("",m("",m("",m("0000000000000000000000000000000000",(""))))))); +?> +--EXPECTF-- +Warning: array_map() expects parameter 1 to be a valid callback, function '0000000000000000000000000000000000' not found or invalid function name in %sbug70898.php on line %d + +Warning: array_map() expects parameter 1 to be a valid callback, function '' not found or invalid function name in %sbug70898.php on line %d + +Warning: array_map() expects parameter 1 to be a valid callback, function '' not found or invalid function name in %sbug70898.php on line %d + +Warning: array_map() expects parameter 1 to be a valid callback, function '' not found or invalid function name in %sbug70898.php on line %d + +Warning: array_map() expects parameter 1 to be a valid callback, function '' not found or invalid function name in %sbug70898.php on line %d + +Warning: implode(): Argument must be an array in %sbug70898.php on line %d |