Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 700724 - var_export on negative array indexes returns unsigned index id
var_export on negative array indexes returns unsigned index id
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: php53 (Show other bugs)
5.6
Unspecified Unspecified
unspecified Severity high
: rc
: ---
Assigned To: Joe Orton
BaseOS QE - Apps
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-04-29 04:32 EDT by Patrick Uecker
Modified: 2012-02-21 01:38 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-02-21 01:38:18 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0266 normal SHIPPED_LIVE php53 bug fix update 2012-02-20 10:06:28 EST

  None (edit)
Description Patrick Uecker 2011-04-29 04:32:09 EDT
Description of problem:

in php code having a negative array index - e.g. $dummy[-2]=123; - and using
var_export($dummy,true) returns 2*MAXINT-1 as index id

further details listed here: http://bugs.php.net/52534

This bug is fixed in php itself.


Version-Release number of selected component (if applicable):
CentOS 5.5 and 5.6

php.x86_64  5.1.6-27.el5_5.3  
php53.x8664 5.3.3-1.el5_6.1


How reproducible:
<?php

$dummy[-2]=123;
echo  "<br>";
echo var_export($dummy,true);
echo "<br>";

?>


Steps to Reproduce:
1. put php file on server
2. open it
3.

Actual results:
array ( 18446744073709551614 => 123, )

Expected results:
array ( -2=> 123, )

Additional info:
works fine with php.x86_64 5.1.6-27.el5
Comment 1 Joe Orton 2011-07-16 11:36:45 EDT
Thanks for the report.
Comment 4 errata-xmlrpc 2012-02-21 01:38:18 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0266.html

Note You need to log in before you can comment on or make changes to this bug.