mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
Handle case where scheme is missing from the URL.
This commit is contained in:
parent
4cbf07b4ae
commit
d1d9cd65a1
2 changed files with 14 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2020-01-23 Fred Kiefer <fredkiefer@gmx.de>
|
||||
|
||||
* Source/Additions/NSURL+GNUstepBase.m: Handle case where scheme
|
||||
is missing from the URL.
|
||||
|
||||
2020-01-20 Fred Kiefer <fredkiefer@gmx.de>
|
||||
|
||||
* Source/NSPredicate.m: Allow simple predicates on NSDate.
|
||||
|
|
|
@ -64,8 +64,15 @@
|
|||
NSMutableString *urlString;
|
||||
NSString *s;
|
||||
|
||||
urlString = [scheme mutableCopy];
|
||||
[urlString appendString: @"://"];
|
||||
if (scheme != nil)
|
||||
{
|
||||
urlString = [scheme mutableCopy];
|
||||
[urlString appendString: @"://"];
|
||||
}
|
||||
else
|
||||
{
|
||||
urlString = [[NSMutableString alloc] init];
|
||||
}
|
||||
if ([user length] > 0 || [password length] > 0)
|
||||
{
|
||||
if (nil == (s = user)) s = @"";
|
||||
|
|
Loading…
Reference in a new issue