Commit 6b0b1794 authored by Carola Nitz's avatar Carola Nitz

VLCMedia: Remove attempts to encode urls

This removes bugs where urls were wrongly double encoded,
instead the App needs to ensure that the URL is percent encoded if needed

(cherry picked from commit 1ffd69b8)
parent e1c36f36
......@@ -272,12 +272,7 @@ static void HandleMediaParsedChanged(const libvlc_event_t * event, void * self)
VLCLibrary *library = [VLCLibrary sharedLibrary];
NSAssert(library.instance, @"no library instance when creating media");
if (([[anURL absoluteString] hasPrefix:@"sftp://"]) ||
([[anURL absoluteString] hasPrefix:@"smb://"])) {
url = [[[anURL absoluteString] stringByRemovingPercentEncoding] UTF8String];
} else {
url = [[anURL absoluteString] UTF8String];
url = [[anURL absoluteString] UTF8String];
p_md = libvlc_media_new_location(library.instance, url);
......@@ -956,12 +951,6 @@ NSString *const VLCMediaTracksInformationTextEncoding = @"encoding"; // NSString
urlString = [urlString stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
if (!urlString) {
_url = [NSURL URLWithString:urlString];
if (!_url) /* Attempt to interpret as a file path then */ {
_url = [NSURL fileURLWithPath:urlString];
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment