delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/05/21/08:30:11

From: Alex Vinokur <alexvn AT bigfoot DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: mktime() for 1969 & 2106
Date: Tue, 21 May 2002 15:21:07 +0200
Lines: 173
Message-ID: <3CEA49C3.504@bigfoot.com>
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1020521130646 DOT 7489B-100000 AT is> <acdagr$p28b5$1 AT ID-79865 DOT news DOT dfncis DOT de>
NNTP-Posting-Host: gateway.scopus.net (62.90.123.5)
Mime-Version: 1.0
X-Trace: fu-berlin.de 1021983558 25929613 62.90.123.5 (16 [79865])
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.4.1) Gecko/20020314 Netscape6/6.2.2
X-Accept-Language: en-us
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com


Alex Vinokur wrote:

> "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il> wrote in message news:Pine DOT SUN DOT 3 DOT 91 DOT 1020521130646 DOT 7489B-100000 AT is...
> |
> | On Tue, 21 May 2002, Alex Vinokur wrote:
> |
> | > It seems that not 'all results for 1969 and 2106' are valid.
> |
> | That's because your time zone is not GMT0, but something else.  The range
> | of times that mktime can represent is defined in the GMT0 zone (a.k.a.
> | UTC time); for all other zones, mktime does the appropriate correction.
> | That's why the first valid time for your machine is in 1969, not January
> | 1, 1970.
> |
> | For the record: what is your timezone, as set on your DJGPP machine?
> 
> zoneinfo was missing on my DJGPP machine.
> 
> | The headers of your message seem to indicate it's +0400, is that what you
> | have on the DJGPP machine?
> |
> | > Is something wrong?
> |
> | No.  You just need to make sure your TZ environment variable is set to
> | your time zone.  See section 22.20 of the DJGPP FAQ list for more
> | details.
> |
> | Also make sure you have the latest upload of djtzn203.zip from SimTel:
> | the initial upload had a bug in the generated timezone files.
> |
> 
> 
> Thanks.
> 
> I download djtzn203.zip from SimTel (by the way, this file name is missing in list of zip files).
> Now my DJGPP machine contains zoneinfo with its subdirectories and files.
> TZ=c:/djgpp/zoneinfo/israel
> 
> Here are a new run log file.
> 
> ------ BEGIN ------
> DATA-TIME  1969:12:31::00:00:57 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:00:58 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:00:59 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:01:00 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:01:01 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:01:02 ---> mktime() can't return required time
> 
> DATA-TIME  1969:12:31::00:59:57 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:59:58 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::00:59:59 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:00:00 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:00:01 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:00:02 ---> mktime() can't return required time
> 
> DATA-TIME  1969:12:31::01:00:57 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:00:58 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:00:59 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:01:00 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:01:01 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::01:01:02 ---> mktime() can't return required time
> 
> DATA-TIME  1969:12:31::23:00:57 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:00:58 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:00:59 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:01:00 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:01:01 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:01:02 ---> mktime() can't return required time
> 
> DATA-TIME  1969:12:31::23:59:57 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:59:58 ---> mktime() can't return required time
> DATA-TIME  1969:12:31::23:59:59 ---> mktime() can't return required time
> DATA-TIME  1970:01:01::00:00:00 ---> 004294960096
> DATA-TIME  1970:01:01::00:00:01 ---> 004294960097
> DATA-TIME  1970:01:01::00:00:02 ---> 004294960098
> 
> 
> DATA-TIME  2106:02:07::06:28:12 ---> 004294960092
> DATA-TIME  2106:02:07::06:28:13 ---> 004294960093
> DATA-TIME  2106:02:07::06:28:14 ---> 004294960094
> DATA-TIME  2106:02:07::06:28:15 ---> 004294960095
> DATA-TIME  2106:02:07::06:28:16 ---> 004294960096
> DATA-TIME  2106:02:07::06:28:17 ---> 004294960097
> DATA-TIME  2106:02:07::06:28:18 ---> 004294960098
> 
> DATA-TIME  2106:02:07::06:28:57 ---> 004294960137
> DATA-TIME  2106:02:07::06:28:58 ---> 004294960138
> DATA-TIME  2106:02:07::06:28:59 ---> 004294960139
> DATA-TIME  2106:02:07::06:29:00 ---> 004294960140
> DATA-TIME  2106:02:07::06:29:01 ---> 004294960141
> DATA-TIME  2106:02:07::06:29:02 ---> 004294960142
> ------ END --------
> 
> 
> It seems that new log file is better than old one.
> However, what happened to 1970 ?
> 
>



[snip]

Here is an updated log file.

------ BEGIN ------

DATA-TIME  1969:12:31::23:00:57 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:00:58 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:00:59 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:01:00 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:01:01 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:01:02 ---> mktime() can't return required time

DATA-TIME  1969:12:31::23:59:57 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:59:58 ---> mktime() can't return required time
DATA-TIME  1969:12:31::23:59:59 ---> mktime() can't return required time
DATA-TIME  1970:01:01::00:00:00 ---> 004294960096
DATA-TIME  1970:01:01::00:00:01 ---> 004294960097
DATA-TIME  1970:01:01::00:00:02 ---> 004294960098

DATA-TIME  1970:01:01::01:00:00 ---> 004294963696
DATA-TIME  1970:01:01::01:00:01 ---> 004294963697
DATA-TIME  1970:01:01::01:00:02 ---> 004294963698

DATA-TIME  1970:01:01::01:59:57 ---> 004294967293
DATA-TIME  1970:01:01::01:59:58 ---> 004294967294
DATA-TIME  1970:01:01::01:59:59 ---> mktime() can't return required time
DATA-TIME  1970:01:01::02:00:00 ---> 000000000000
DATA-TIME  1970:01:01::02:00:01 ---> 000000000001
DATA-TIME  1970:01:01::02:00:02 ---> 000000000002

DATA-TIME  1970:01:01::03:00:00 ---> 000000003600
DATA-TIME  1970:01:01::03:00:01 ---> 000000003601
DATA-TIME  1970:01:01::03:00:02 ---> 000000003602



DATA-TIME  2106:02:07::06:28:12 ---> 004294960092
DATA-TIME  2106:02:07::06:28:13 ---> 004294960093
DATA-TIME  2106:02:07::06:28:14 ---> 004294960094
DATA-TIME  2106:02:07::06:28:15 ---> 004294960095
DATA-TIME  2106:02:07::06:28:16 ---> 004294960096
DATA-TIME  2106:02:07::06:28:17 ---> 004294960097
DATA-TIME  2106:02:07::06:28:18 ---> 004294960098

DATA-TIME  2106:02:07::06:28:57 ---> 004294960137
DATA-TIME  2106:02:07::06:28:58 ---> 004294960138
DATA-TIME  2106:02:07::06:28:59 ---> 004294960139
DATA-TIME  2106:02:07::06:29:00 ---> 004294960140
DATA-TIME  2106:02:07::06:29:01 ---> 004294960141
DATA-TIME  2106:02:07::06:29:02 ---> 004294960142

------ END --------

We can see that still there is a problem in interval
[ 1970:01:01::00:00:00  -  1970:01:01::01:59:58 ].

 



-- 
   ============================
   Alex Vinokur
     http://up.to/alexvn
     http://go.to/alexv_math
     mailto:alexvn AT bigfoot DOT com
     mailto:alexvn AT go DOT to
   ============================

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019