mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 00:11:26 +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
|
@ -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…
Add table
Add a link
Reference in a new issue