Bug 8472 - Incorrect computation of GMT time
Summary: Incorrect computation of GMT time
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: php
Version: 6.1
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Preston Brown
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-01-14 15:49 UTC by S. William Schulz
Modified: 2008-05-01 15:37 UTC (History)
0 users

(edit)
Clone Of:
(edit)
Last Closed: 2000-02-17 16:07:20 UTC


Attachments (Terms of Use)

Description S. William Schulz 2000-01-14 15:49:09 UTC
As installed, RH 6.1, php3, and apache-1.3.9 (and/or SWS 3.1) yield
incorrect values when calling gmmktime, e.g. calling gmmktime and mktime
yield the same (local) time values:

<P><? echo gmmktime(0,0,0,1,1,2000) ?></P>
<P><? echo   mktime(0,0,0,1,1,2000) ?></P>

yields

946702800
946702800

when the two should differ by 5 hours (86400 secs) (in my case).  Not sure
if this is a configuration problem elsewhere.  I could find no TZ config
info in php.ini.

Perl gmtime() yields the expected values.

Comment 1 Preston Brown 2000-02-17 16:07:59 UTC
for php 3.0.14 that will ship with 6.2, these are the results:

946684800

946702800

on my system, which is correct.  This poblem appears to be corrected.


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