summaryrefslogtreecommitdiff
path: root/ext/mbstring/tests/bug73646.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mbstring/tests/bug73646.phpt')
-rw-r--r--ext/mbstring/tests/bug73646.phpt11
1 files changed, 11 insertions, 0 deletions
diff --git a/ext/mbstring/tests/bug73646.phpt b/ext/mbstring/tests/bug73646.phpt
new file mode 100644
index 0000000000..a6aefb22d4
--- /dev/null
+++ b/ext/mbstring/tests/bug73646.phpt
@@ -0,0 +1,11 @@
+--TEST--
+Bug #73646 (mb_ereg_search_init null pointer dereference)
+--FILE--
+<?php
+
+$v1=str_repeat("#", -1);
+var_dump(mb_ereg_search_init($v1));
+?>
+--EXPECTF--
+Warning: str_repeat(): Second argument has to be greater than or equal to 0 in %sbug73646.php on line %d
+bool(true)