mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2026-06-17 22:23:31 +00:00
Escaping the URL strings is not required because no reserved characters are ever sent. Plus it's deprecated in iOS 9.
This commit is contained in:
@@ -42,8 +42,7 @@ static const NSString* PORT = @"47984";
|
|||||||
_uniqueId = uniqueId;
|
_uniqueId = uniqueId;
|
||||||
_deviceName = deviceName;
|
_deviceName = deviceName;
|
||||||
_cert = cert;
|
_cert = cert;
|
||||||
_baseURL = [[NSString stringWithFormat:@"https://%@:%@", host, PORT]
|
_baseURL = [NSString stringWithFormat:@"https://%@:%@", host, PORT];
|
||||||
stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
|
|
||||||
_requestLock = dispatch_semaphore_create(0);
|
_requestLock = dispatch_semaphore_create(0);
|
||||||
_respData = [[NSMutableData alloc] init];
|
_respData = [[NSMutableData alloc] init];
|
||||||
return self;
|
return self;
|
||||||
@@ -68,8 +67,7 @@ static const NSString* PORT = @"47984";
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (NSURLRequest*) createRequestFromString:(NSString*) urlString enableTimeout:(BOOL)normalTimeout {
|
- (NSURLRequest*) createRequestFromString:(NSString*) urlString enableTimeout:(BOOL)normalTimeout {
|
||||||
NSString* escapedUrl = [urlString stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
|
NSURL* url = [[NSURL alloc] initWithString:urlString];
|
||||||
NSURL* url = [[NSURL alloc] initWithString:escapedUrl];
|
|
||||||
NSMutableURLRequest* request = [NSMutableURLRequest requestWithURL:url];
|
NSMutableURLRequest* request = [NSMutableURLRequest requestWithURL:url];
|
||||||
if (normalTimeout) {
|
if (normalTimeout) {
|
||||||
// Timeout the request after 5 seconds
|
// Timeout the request after 5 seconds
|
||||||
|
|||||||
Reference in New Issue
Block a user