harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexei Zakharov (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-5476) [classlib][luni] Harmony is unable to detect correct time zone on Linux
Date Fri, 08 Feb 2008 13:49:07 GMT
[classlib][luni] Harmony is unable to detect correct time zone on Linux

                 Key: HARMONY-5476
                 URL: https://issues.apache.org/jira/browse/HARMONY-5476
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
         Environment: Linux32
            Reporter: Alexei Zakharov
            Assignee: Alexei Zakharov

On Linux auto detection of default time zone works incorrectly. For example SimpleDateFormat
always returns GMT +0 by default. This leads to incorrect work of some applications - Clock
demo applet from RI distribution could be one of such examples. Please see the test case below:

import java.text.SimpleDateFormat;
import java.util.TimeZone;

public class DateTest {

    public static void main(String argv[]) {
        SimpleDateFormat formatter;

        formatter = new SimpleDateFormat();
                true, TimeZone.SHORT) + ", " +
                formatter.getTimeZone().getDisplayName(true, TimeZone.LONG));

On RI (my workstation is located in Moscow, GMT+3):
MSD, Moscow Daylight Time

on Harmony (r619813):
GMT+00:00, GMT+00:00

However, on Windows Harmony correctly sets time zone to GMT +3. So this is a UNIX-only issue.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message