This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

libgcj/3499: Calendar return GMT in non-GMT timezone, such as JST-9



>Number:         3499
>Category:       libgcj
>Synopsis:       Calendar return GMT in non-GMT timezone, such as JST-9
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          wrong-code
>Submitter-Id:   net
>Arrival-Date:   Sat Jun 30 14:06:01 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Tsujikawa Tohru
>Release:        gcc version 3.0
>Organization:
>Environment:
x86, Linux-2.4.5, glibc 2.2.3
>Description:
in libgcj/java/util/natGregorianCalendar.cc, computeFields():

> if (zone->getRawOffset() == 0 || ! zone->useDaylightTime())
>   {
> (suppressed)
>       tim = *(struct tm*) gmtime (&t);
> (suppressed)
>   }
> else
>   {
> (suppressed)
>       tim = *(struct tm*) localtime (&t);
> (suppressed)
> }


I think this should be:

> if (zone->getRawOffset() == 0 || zone->useDaylightTime())

In Japan, timezone is JST-9 and no daylight time.
So, this function returns GMT.
>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]