discuss-gnustep
[Top][All Lists]
Advanced

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

Initializing time zone on OpenBSD


From: Sebastian Reitenbach
Subject: Initializing time zone on OpenBSD
Date: Fri, 01 Jun 2007 06:51:23 +0200

Hi,

I am working on porting OGo from lF to gnustep-base, on a OpenBSD box. While 
the timezone is set on OGo startup, I noticed a non fatal exception.

Breakpoint 2, -[NSException raise] (self=0x8b0b0a28, _cmd=0x2df74598) at 
NSException.m:782
782       if (GSPrivateEnvironmentFlag("GNUSTEP_STACK_TRACE", NO) == YES
Current language:  auto; currently objective-c
(gdb) bt
#0  -[NSException raise] (self=0x8b0b0a28, _cmd=0x2df74598) at 
NSException.m:782
#1  0x0df545a2 in +[NSException raise:format:arguments:] (self=0x2df743a0, 
_cmd=0x2df74580, name=0x2df8ba00, format=0x2df8ba30,
    argList=0xcfbcedc0 "") at NSException.m:753
#2  0x0df544f3 in +[NSException raise:format:] (self=0x2df743a0, 
_cmd=0x2df8c858, name=0x2df8ba00, format=0x2df8ba30) at NSException.m:739
#3  0x0dfed2c0 in -[GSTimeZone initWithName:data:] (self=0x804e61c8, 
_cmd=0x2df8c740, name=0x8b0b08e8, data=0x8b0b0908) at NSTimeZone.m:2661
#4  0x0dfe866f in -[GSPlaceholderTimeZone initWithName:data:] 
(self=0x8b711ad8, _cmd=0x2df8c740, name=0x8b0b08e8, data=0x8b0b0908)
    at NSTimeZone.m:491
#5  0x0dfeba2d in +[NSTimeZone timeZoneArray] (self=0x2df8c040, 
_cmd=0x2df8c878) at NSTimeZone.m:1614
#6  0x0dfea651 in +[NSTimeZone knownTimeZoneNames] (self=0x2df8c040, 
_cmd=0x2df8c810) at NSTimeZone.m:1166
#7  0x0dfe9937 in +[NSTimeZone abbreviationDictionary] (self=0x2df8c040, 
_cmd=0x2df8c938) at NSTimeZone.m:965
#8  0x0dfebe72 in +[NSTimeZone timeZoneWithAbbreviation:] (self=0x2df8c040, 
_cmd=0x22f69778, abbreviation=0x22f6909c) at NSTimeZone.m:1696
#9  0x02f823e0 in OWGetProperty () from /usr/local/lib/libNGObjWeb.so.4.7.9
#10 0x0815ac0c in __objc_send_initialize (class=0x22f696e0) 
at /usr/src/gnu/lib/libobjc/libobjc/sendmsg.c:324
#11 0x0815aaa4 in __objc_init_install_dtable (receiver=0x22f696e0, 
op=0x22f61430) at /usr/src/gnu/lib/libobjc/libobjc/sendmsg.c:266
#12 0x0815ba28 in objc_msg_lookup (receiver=0x22f696e0, op=0x22f61430) 
at /usr/src/gnu/lib/libobjc/libobjc/sendmsg.c:184
#13 0x02f5df22 in WOGetKVCValueUsingMethod () 
from /usr/local/lib/libNGObjWeb.so.4.7.9
#14 0x02f5e1a5 in WOGetKVCValueUsingMethod () 
from /usr/local/lib/libNGObjWeb.so.4.7.9
#15 0x0300ecef in OWFormElementName () 
from /usr/local/lib/libNGObjWeb.so.4.7.9
#16 0x1c00350e in -[OpenGroupware init] (self=0x81435208, _cmd=0x22f6d7c8) 
at OpenGroupware.m:250
#17 0x02f92dff in WOApplicationMain () 
from /usr/local/lib/libNGObjWeb.so.4.7.9
#18 0x02fb2c13 in WOWatchDogApplicationMain () 
from /usr/local/lib/libNGObjWeb.so.4.7.9
#19 0x1c001c88 in gnustep_base_user_main (argc=3, argv=0xcfbcf454, 
env=0xcfbcf464) at main.m:32
#20 0x0dfaa16b in main (argc=3, argv=0xcfbcf454, env=0xcfbcf464) at 
NSProcessInfo.m:897
#21 0x1c001b50 in ___start ()
#22 0x1c001abf in _start ()
#23 0x00000000 in ?? ()


looking at NSTimeZone.m I read this in the header:
   The local time zone can be specified with:
    1) the user defaults database
    2) the GNUSTEP_TZ environment variable
    3) the file LOCAL_TIME_FILE in _time_zone_path()
    4) the TZ environment variable
    5) TZDEFAULT defined in tzfile.h on platforms which have it
    6) tzset() & tznam[] for platforms which have it
    7) Windows registry, for Win32 systems
    8) or the fallback time zone (which is UTC)
   with the ones listed first having precedence.

When I set the GNUSTEP_TZ to e.g. Europe/Berlin, then no exception happens. 
But without that variable, it walks through all timezones 
in /usr/share/zoneinfo/. In that directory there is a file called zone.tab. 
This file is parsed too, and the exception is raised.

So the exception is non fatal, I can continue in gdb. Then I see the 
following warning:

2007-06-01 06:48:35.963 ogo-webui-1.1[28993] Unable to obtain time zone 
`zone.tab'... <NSException: 0x8b0b0a28> NAME:GSTimeZoneFileException 
REASON:Transitions list is truncated

As said, defining GNUSTEP_TZ fixes the problem.

As it is a non fatal exception, I don't know whether it is an issue. I just 
wanted to mention it here.

kind regards
Sebastian





reply via email to

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