aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/adm/index.php
diff options
context:
space:
mode:
authorOleg Pudeyev <oleg@bsdpower.com>2011-02-01 21:50:44 -0500
committerAndreas Fischer <bantu@phpbb.com>2011-02-04 00:01:49 +0100
commit15992ceff99cd147d30b81fa237424160779f916 (patch)
tree721a6e7e8ba1d5e8547161d3167dd365f2fac192 /phpBB/adm/index.php
parentb414a4d107b3baa4b6d2f600e6f52211359ec3a5 (diff)
downloadforums-15992ceff99cd147d30b81fa237424160779f916.tar
forums-15992ceff99cd147d30b81fa237424160779f916.tar.gz
forums-15992ceff99cd147d30b81fa237424160779f916.tar.bz2
forums-15992ceff99cd147d30b81fa237424160779f916.tar.xz
forums-15992ceff99cd147d30b81fa237424160779f916.zip
[ticket/10020] Replaced (int) 0x80000000 with portable equivalent.
PHPBB3-10020
Diffstat (limited to 'phpBB/adm/index.php')
-rw-r--r--phpBB/adm/index.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/phpBB/adm/index.php b/phpBB/adm/index.php
index 92bcf90039..b6ccb6b241 100644
--- a/phpBB/adm/index.php
+++ b/phpBB/adm/index.php
@@ -573,7 +573,8 @@ function validate_range($value_ary, &$error)
'BOOL' => array('php_type' => 'int', 'min' => 0, 'max' => 1),
'USINT' => array('php_type' => 'int', 'min' => 0, 'max' => 65535),
'UINT' => array('php_type' => 'int', 'min' => 0, 'max' => (int) 0x7fffffff),
- 'INT' => array('php_type' => 'int', 'min' => (int) 0x80000000, 'max' => (int) 0x7fffffff),
+ // Do not use (int) 0x80000000 - it evaluates to different values on 32-bit and 64-bit systems.
+ 'INT' => array('php_type' => 'int', 'min' => -2147483648, 'max' => (int) 0x7fffffff),
'TINT' => array('php_type' => 'int', 'min' => -128, 'max' => 127),
'VCHAR' => array('php_type' => 'string', 'min' => 0, 'max' => 255),