Annotation of embedaddon/php/ext/mbstring/tests/bug43301.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Bug #43301 (mb_ereg*_replace() crashes when replacement string is invalid PHP expression and 'e' option is used)
3: --SKIPIF--
4: <?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
5: --FILE--
6: <?php
7:
8: $ptr = 'hello';
9:
10: $txt = <<<doc
11: hello, I have got a cr*sh on you
12: doc;
13:
14: echo mb_ereg_replace($ptr,'$1',$txt,'e');
15:
16: ?>
17: --EXPECTF--
18: Parse error: syntax error, unexpected T_LNUMBER, expecting T_VARIABLE or '$' in %sbug43301.php(%d) : mbregex replace on line 1
19:
20: Fatal error: mb_ereg_replace(): Failed evaluating code:
21: $1 in %sbug43301.php on line %d
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>