xref: /php-src/Zend/tests/bug70898.phpt (revision 99d0f502)
1--TEST--
2Bug #70895 null ptr deref and segfault with crafted callable
3--FILE--
4<?php
5function m($f,$a){
6    return array_map($f,0);
7}
8
9try {
10    echo implode(m("",m("",m("",m("",m("0000000000000000000000000000000000",("")))))));
11} catch (TypeError $e) {
12    echo $e->getMessage(), "\n";
13}
14?>
15--EXPECT--
16array_map(): Argument #1 ($callback) must be a valid callback or null, function "0000000000000000000000000000000000" not found or invalid function name
17