mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-18 11:41:06 +00:00
Skip .tab files when looking for zones.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@25265 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
44a5416522
commit
c1771ce6bb
2 changed files with 11 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2007-06-15 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
|
* Source/NSTimeZone.m ([NSTimeZone +timeZoneArray]): Skip .tab
|
||||||
|
files when looking for zones.
|
||||||
|
|
||||||
2007-06-14 Richard Frith-Macdonald <rfm@gnu.org>
|
2007-06-14 Richard Frith-Macdonald <rfm@gnu.org>
|
||||||
|
|
||||||
* Source/NSNumber.m: Implement ([isEqualToValue:])
|
* Source/NSNumber.m: Implement ([isEqualToValue:])
|
||||||
|
|
|
@ -1594,11 +1594,10 @@ static NSMapTable *absolutes = 0;
|
||||||
NSTimeZone *zone = nil;
|
NSTimeZone *zone = nil;
|
||||||
BOOL isDir;
|
BOOL isDir;
|
||||||
|
|
||||||
// FIXME: check file validity.
|
|
||||||
|
|
||||||
path = [zonedir stringByAppendingPathComponent: name];
|
path = [zonedir stringByAppendingPathComponent: name];
|
||||||
if ([mgr fileExistsAtPath: path isDirectory: &isDir]
|
if ([mgr fileExistsAtPath: path isDirectory: &isDir]
|
||||||
&& isDir == NO)
|
&& isDir == NO
|
||||||
|
&& [[path pathExtension] isEqual: @"tab"] == NO)
|
||||||
{
|
{
|
||||||
zone = [zoneDictionary objectForKey: name];
|
zone = [zoneDictionary objectForKey: name];
|
||||||
if (zone == nil)
|
if (zone == nil)
|
||||||
|
@ -1606,6 +1605,10 @@ static NSMapTable *absolutes = 0;
|
||||||
NSData *data;
|
NSData *data;
|
||||||
|
|
||||||
data = [NSData dataWithContentsOfFile: path];
|
data = [NSData dataWithContentsOfFile: path];
|
||||||
|
/* We should really make sure this is a real
|
||||||
|
zone file and not something extra that happens
|
||||||
|
to be in this directory, but initWithName:data:
|
||||||
|
will do this anyway and log a message if not. */
|
||||||
zone = [[self alloc] initWithName: name data: data];
|
zone = [[self alloc] initWithName: name data: data];
|
||||||
AUTORELEASE(zone);
|
AUTORELEASE(zone);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue