mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 16:50:58 +00:00
Formatting tidyups
This commit is contained in:
parent
2adc5c5959
commit
1fe008304a
2 changed files with 58 additions and 53 deletions
|
@ -105,7 +105,8 @@ GS_EXPORT_CLASS
|
||||||
|
|
||||||
/** Create and return a file URL with the supplied path, relative to a base URL.
|
/** Create and return a file URL with the supplied path, relative to a base URL.
|
||||||
*/
|
*/
|
||||||
+ (instancetype) fileURLWithPath:(NSString *)aPath relativeToURL:(NSURL *)baseURL;
|
+ (instancetype) fileURLWithPath: (NSString *)aPath
|
||||||
|
relativeToURL: (NSURL *)baseURL;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -665,17 +665,17 @@ static NSUInteger urlAlign;
|
||||||
|
|
||||||
if (nil == aPath)
|
if (nil == aPath)
|
||||||
{
|
{
|
||||||
[NSException
|
[NSException raise: NSInvalidArgumentException
|
||||||
raise:NSInvalidArgumentException
|
format: @"[%@ %@] nil string parameter",
|
||||||
format:@"[%@ %@] nil string parameter", NSStringFromClass([self class]),
|
NSStringFromClass([self class]), NSStringFromSelector(_cmd)];
|
||||||
NSStringFromSelector(_cmd)];
|
|
||||||
}
|
}
|
||||||
if ([aPath isAbsolutePath] == NO)
|
if ([aPath isAbsolutePath] == NO)
|
||||||
{
|
{
|
||||||
if (baseURL)
|
if (baseURL)
|
||||||
{
|
{
|
||||||
/* Append aPath to baseURL */
|
/* Append aPath to baseURL */
|
||||||
aPath = [[baseURL relativePath] stringByAppendingPathComponent:aPath];
|
aPath
|
||||||
|
= [[baseURL relativePath] stringByAppendingPathComponent: aPath];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -2177,7 +2177,9 @@ GS_PRIVATE_INTERNAL(NSURLQueryItem)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ASSIGN(internal->_name, @""); //OSX behaviour is to set an empty string for nil name property
|
/* OSX behaviour is to set an empty string for nil name property
|
||||||
|
*/
|
||||||
|
ASSIGN(internal->_name, @"");
|
||||||
}
|
}
|
||||||
ASSIGNCOPY(internal->_value, value);
|
ASSIGNCOPY(internal->_value, value);
|
||||||
}
|
}
|
||||||
|
@ -2310,7 +2312,9 @@ static NSCharacterSet *queryItemCharSet = nil;
|
||||||
|
|
||||||
- (instancetype) initWithString: (NSString *)URLString
|
- (instancetype) initWithString: (NSString *)URLString
|
||||||
{
|
{
|
||||||
//OSX behavior is to return nil for a string which cannot be used to initialize valid NSURL object
|
/* OSX behavior is to return nil for a string which cannot be
|
||||||
|
* used to initialize valid NSURL object
|
||||||
|
*/
|
||||||
NSURL *url = [NSURL URLWithString: URLString];
|
NSURL *url = [NSURL URLWithString: URLString];
|
||||||
if (url)
|
if (url)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue