We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6c4fa3b commit ffcd366Copy full SHA for ffcd366
ext/bz2/tests/gh20620.phpt
@@ -0,0 +1,18 @@
1
+--TEST--
2
+Bug GH-20620 (bzcompress with large source)
3
+--EXTENSIONS--
4
+bz2
5
+--SKIPIF--
6
+<?php if (PHP_INT_SIZE != 8) die('skip this test is for 64bit platforms only');i ?>
7
+--INI--
8
+memory_limit=-1
9
+--FILE--
10
+<?php
11
+try {
12
+ bzcompress(str_repeat('1', 4295163906));
13
+} catch (\ValueError $e) {
14
+ echo $e->getMessage(), PHP_EOL;
15
+}
16
+?>
17
+--EXPECTF--
18
+bzcompress(): Argument #1 ($data) must be less than or equal to %d
0 commit comments