Bug 114871

Summary: TZ variable not able to properly manipulate date
Product: Red Hat Enterprise Linux 2.1 Reporter: Timothy Toedebusch <tt8618>
Component: glibcAssignee: Jakub Jelinek <jakub>
Status: CLOSED NOTABUG QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.1CC: fweimer, twaugh
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-02-09 15:41:10 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Timothy Toedebusch 2004-02-03 20:14:36 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)

Description of problem:
I am attempting to manipulate the date to show me the time/date 
exactly 24 hours ago.
I attempt to do this using the following convention from command line 
or in a script:

"TZ=CDT30CST date"  
This should give me a date exactly 24 hours ago, but here is what I 
am seeing:
# date
Tue Feb  3 14:16:02 CST 2004
TZ=CST30CDT date
Mon Feb  2 21:16:03 CST 2004

I am located in the Central time zone and am using bash.

Version-Release number of selected component (if applicable):
sh-utils-2.0.11-5

How reproducible:
Always

Steps to Reproduce:
1. date; TZ=XXX30YYY date (where XXX and YYY reflect the time zone)
2.
3.
    

Additional info:

Comment 1 Tim Waugh 2004-02-04 13:06:27 UTC
Date just reports what localtime() says.

Comment 2 Jakub Jelinek 2004-02-09 15:41:10 UTC
See http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap08.html
Particularly:
The hour shall be between zero and 24...
and
The result of using values outside of this range is unspecified.