|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits              [2016-03-25 17:45 UTC] danack@php.net
 
-Status: Open
+Status: Feedback
  [2016-03-25 17:45 UTC] danack@php.net
  [2016-03-26 12:17 UTC] david at frankieandshadow dot com
  [2016-04-03 04:22 UTC] php-bugs at lists dot php dot net
 | |||||||||||||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Fri Oct 31 11:00:01 2025 UTC | 
Description: ------------ This is actually version 5.6.17, it is not practical for me to upgrade currently. 5.6.17 is the most up to date Debian Jessie distribution. The json_decode function produces PHP Notice: json_decode(): integer overflow detected in .../test.php on line 11 when the value concerned is 9223372036854775807 (i.e. PHP_INT_MAX), which is a valid value. This has a particular impact in decoding certain results from elasticsearch which contain max int values. Test script: --------------- <?php echo PHP_INT_MAX, "\n"; $a = array('a' => PHP_INT_MAX); /* it works OK if you put PHP_INT_MAX-1 here */ print_r($a); $j = json_encode($a); echo $j, "\n"; $b = json_decode($j); /* produces the incorrect error message */ print_r($b); Expected result: ---------------- No warning. Actual result: -------------- PHP Notice: json_decode(): integer overflow detected