Expand tilde in bundle path.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@21336 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
CaS 2005-06-21 12:55:30 +00:00
parent b5ae635b68
commit b71746b96d
2 changed files with 8 additions and 0 deletions

View file

@ -1,3 +1,7 @@
2005-06-21 Richard Frith-Macdonald <rfm@gnu.org>
* Source/NSBundle.m: ([-initWithPath:]) expand paths with tildes.
2005-06-17 Richard Frith-Macdonald <rfm@gnu.org>
* Source/NSConnection.m: Removed bogus

View file

@ -900,6 +900,10 @@ _bundle_load_callback(Class theClass, struct objc_category *theCategory)
path = [[[NSFileManager defaultManager] currentDirectoryPath]
stringByAppendingPathComponent: path];
}
if ([path hasPrefix: @"~"] == YES)
{
path = [path stringByExpandingTildeInPath];
}
/* Check if we were already initialized for this directory */
[load_lock lock];