America/Sao_Paulo DST problem

Stefano Scarponi stefano.scarponi at
Thu May 27 16:17:47 UTC 2004

Hi all,
During an investigation about customer brazilian problem
I downloaded your latest tz lib from "".

I build and install the library on Linux Redhat 9.

I created a simple "my_date.c" that perform a mktime into the range 00:00 -
14 Feb 2004 to  23:59 - 15 Feb 2004.
The DST from Brasil Sao_Paulo is the following:

file southamerica:

Rule    Brazil  2000    2001    -       Oct     Sun>=8   0:00   1:00    S
Rule    Brazil  2001    max     -       Feb     Sun>=15  0:00   0       -
Rule    Brazil  2002    only    -       Nov      3       0:00   1:00    S
Rule    Brazil  2003    max     -       Oct     Sun>=15  0:00   1:00    S

So for the DST about Feb Sun>=15 at 0:00 I expected that the DST occurs at
0:00 15 Feb,
but I saw that it occurs at 23:49 14 Feb as you can see from the output

 I set the TZ to TZ=America/Sao_Paulo

date =<day=14 hours=23 min=45> diff=-60 epoque=1076809501 DST=<1>
date =<day=14 hours=23 min=46> diff=-60 epoque=1076809561 DST=<1>
date =<day=14 hours=23 min=47> diff=-60 epoque=1076809621 DST=<1>
date =<day=14 hours=23 min=48> diff=-60 epoque=1076809681 DST=<1>
date =<day=14 hours=23 min=49> diff=-3660 epoque=1076813341 DST=<0>
<-------- DST occurs here
date =<day=14 hours=23 min=50> diff=-60 epoque=1076813401 DST=<0>
date =<day=14 hours=23 min=51> diff=-60 epoque=1076813461 DST=<0>
date =<day=14 hours=23 min=52> diff=-60 epoque=1076813521 DST=<0>
date =<day=14 hours=23 min=53> diff=-60 epoque=1076813581 DST=<0>
date =<day=14 hours=23 min=54> diff=-60 epoque=1076813641 DST=<0>

I think that this is a bug because the DST is for 15 Feb at 0:00 and NOT
23:49 14 Feb.

Do you have some suggestions or do you already knows about this problem?

This is my "my_date.c"

(See attached file: my_date.c)



-------------- next part --------------
A non-text attachment was scrubbed...
Name: my_date.c
Type: application/octet-stream
Size: 2045 bytes
Desc: not available
Url : 

More information about the tz mailing list