Commit 78692d43 authored by Sebastien Zwickert's avatar Sebastien Zwickert Committed by Felix Paul Kühne

VLCKit: remove the prefix from the parameter value and take into account null...

VLCKit: remove the prefix from the parameter value and take into account null values for options that do not require a value.
Signed-off-by: Felix Paul Kühne's avatarFelix Paul Kühne <fkuehne@videolan.org>
parent 3ed20a07
......@@ -357,7 +357,11 @@ static void HandleMediaSubItemAdded(const libvlc_event_t * event, void * self)
for( NSString * key in [options allKeys] )
{
libvlc_media_add_option(p_md, [[NSString stringWithFormat:@"%@=#%@", key, [options objectForKey:key]] UTF8String]);
if ( [options objectForKey:key] != [NSNull null] )
libvlc_media_add_option(p_md, [[NSString stringWithFormat:@"%@=%@", key, [options objectForKey:key]] UTF8String]);
else
libvlc_media_add_option(p_md, [[NSString stringWithFormat:@"%@", key] UTF8String]);
}
return [VLCMedia mediaWithLibVLCMediaDescriptor:p_md];
}
......
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