bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Bug report for "date"


From: Paul Grinberg
Subject: RE: Bug report for "date"
Date: Tue, 28 Jul 2009 19:42:28 -0400

Shell script for Solaris....It can go future as long as I want, but past
only 6 days....

http://www.isrcomputing.com/index.php?option=com_content&view=article&id
=125:unix-shell-script-to-calculate-date-in-the-future-and-in-the-past&c
atid=38:technology-tips&Itemid=82


Best,
Paul


-----Original Message-----
From: Philip Rowlands [mailto:address@hidden 
Sent: Tuesday, July 28, 2009 7:40 PM
To: Paul Grinberg
Cc: address@hidden
Subject: Re: Bug report for "date"

On Tue, 28 Jul 2009, Paul Grinberg wrote:

> Gives me correct date:
>
> [ctpsmg11-dcdhealth@/opt/app/dcdhealth] # TZ=EDT+150 date
> Wed Jul 22 12:27:15 EDT 2009
>
> Gives me incorrect date:
> [ctpsmg11-dcdhealth@/opt/app/dcdhealth] # TZ=EDT+172 date
> Tue Jul 28 18:27:09 GMT 2009
>
> Basically I cannot go back more than 6 days...

According to the POSIX/glibc definition of TZ:
http://www.opengroup.org/onlinepubs/000095399/basedefs/xbd_chap08.html
http://www.gnu.org/s/libc/manual/html_node/TZ-Variable.html

the hour offset must be between 0 and 24. In other words, the examples 
above are undefined by the standards. Why are you trying to use TZ to 
concoct multi-day offsets?


Cheers,
Phil




reply via email to

[Prev in Thread] Current Thread [Next in Thread]