JDK-4267616 : wrong time offsets, and short time representation [NT jdk1.2.1's TimeZone]
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util:i18n
  • Affected Version: 1.2.2
  • Priority: P2
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_nt
  • CPU: x86
  • Submitted: 1999-09-01
  • Updated: 1999-09-01
  • Resolved: 1999-09-01
Related Reports
Duplicate :  
Relates :  
Description
The jdk1.2.x's SimpleDateFormat.format() either produces GMT+xx strings instead of 
the expected 3 letter acronyms (short time representation) for specific 
time zones (see table below), and/or displays the wrong times (1 hour offset)
in several cases.
 



Procedure to recreate the failures
==================================

1. Change time zone setting in Date/time panel of Windows NT
2. Note the date and time.
3. Using java, do a System.out.println(formatter.format(currentTime))
 	where formatter is a SimpleDateFormat, and currentTime is a 
	Data object. 
4. Compare the date/time/timzone in NT with one reported by Java.




Results:
========

NT Setting			TimeZone reported by Java     	Java VM time calculation
----------------------------	-------------------------       ------------------------
Greenwich Mean time (GMT)	GMT				Off by one hour
Berlin, rome, ..    (GMT+1)	GMT+02:00			OK
Paris, Madrid, ..   (GMT+1)	CEST				OK
Israel              (GMT+2)	IDT				Off by one hour
Moscow              (GMT+3)	GMT+04:00			OK
Adilaide            (GMT+9:30)	GMT+09:30			OK
Brisbane, Melbourne (GMT+10)	GMT+10:00			OK
Mexico City         (GMT-6)	GMT-05:00			Off by one hour

 

Comments
EVALUATION Wrong time zone offset comes from problems of Win32 to Java time zone mapping. (bigid: 4252829) "GMT+xx" is a problem of DateFormatZoneData. (bugid: 4261506) Both bugs will be fixed before Kestrel FCS. Closing this bug as a dup of 4261506. masayoshi.okutsu@Eng 1999-09-01
01-09-1999