php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #53729 DatePeriod fails to initialize recurrences s on 64bit big-endian systems
Submitted: 2011-01-12 20:43 UTC Modified: 2011-01-12 20:50 UTC
From: rein at basefarm dot no Assigned: derick (profile)
Status: Closed Package: Date/time related
PHP Version: 5.3.5 OS: Solaris10 on sparc
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: rein at basefarm dot no
New email:
PHP Version: OS:

 

 [2011-01-12 20:43 UTC] rein at basefarm dot no
Description:
------------
In date_period_initialize(), the recurrences argument is an int*, but it is passed a long*.  This causing the wrong value to be returned on 64bit big-endian systems.

A patch that fixes this is attached,  Without this patch, ext/date/tests/bug46874.phpt fails on 64 solaris sparc systems, it only prints the first period.



Patches

bug53729.patch (last revision 2011-01-12 19:44 UTC by rein at basefarm dot no)

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-01-12 20:50 UTC] derick@php.net
Automatic comment from SVN on behalf of derick
Revision: http://svn.php.net/viewvc/?view=revision&revision=307416
Log: - Fixed bug #53729 (DatePeriod fails to initialize recurrences on 64bit
  big-endian systems). (Patch by rein@basefarm.no)
 [2011-01-12 20:50 UTC] derick@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: derick
 [2011-01-12 20:50 UTC] derick@php.net
This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.

Thanks for your patch!
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Mon Apr 07 17:01:29 2025 UTC