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 a75ee02 commit 3bf4115Copy full SHA for 3bf4115
ext/standard/pack.c
@@ -980,7 +980,7 @@ PHP_FUNCTION(unpack)
980
zend_long ipos, opos;
981
982
983
- if (ZEND_LONG_INT_OVFL((zend_long)size * 2)) {
+ if (size > INT_MAX / 2) {
984
zend_string_release(real_name);
985
zend_argument_value_error(1, "repeater must be less than or equal to %d", INT_MAX / 2);
986
RETURN_THROWS();
ext/standard/tests/strings/gh15613.phpt
@@ -1,9 +1,5 @@
1
--TEST--
2
GH-15613 overflow on hex strings repeater value
3
---SKIPIF--
4
-<?php
5
-if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
6
-?>
7
--INI--
8
memory_limit=-1
9
--FILE--
0 commit comments