[vlc-devel] [PATCH 5/6] addons/vorepository: use vlc_stream_NewMRL
Filip Roséen
filip at atch.se
Fri Mar 17 03:22:35 CET 2017
refs: #18131
---
modules/misc/addons/vorepository.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/modules/misc/addons/vorepository.c b/modules/misc/addons/vorepository.c
index 4f25bc8b4e..f2cd6ee383 100644
--- a/modules/misc/addons/vorepository.c
+++ b/modules/misc/addons/vorepository.c
@@ -165,7 +165,7 @@ static int ParseManifest( addons_finder_t *p_finder, addon_entry_t *p_entry,
addon_file_t *p_file = malloc( sizeof(addon_file_t) );
p_file->e_filetype = i_filetype;
p_file->psz_filename = strdup( psz_filename );
- if ( asprintf( & p_file->psz_download_uri, "%s!/%s",
+ if ( asprintf( & p_file->psz_download_uri, "%s#!/%s",
psz_tempfileuri, psz_filename ) > 0 )
{
ARRAY_APPEND( p_entry->files, p_file );
@@ -423,18 +423,18 @@ static int Retrieve( addons_finder_t *p_finder, addon_entry_t *p_entry )
msg_Dbg( p_finder, "Reading manifest from %s", p_finder->p_sys->psz_tempfile );
- char *psz_tempfileuri = vlc_path2uri( p_finder->p_sys->psz_tempfile, "unzip" );
+ char *psz_tempfileuri = vlc_path2uri( p_finder->p_sys->psz_tempfile, NULL );
if ( !psz_tempfileuri )
return VLC_ENOMEM;
char *psz_manifest_uri;
- if ( asprintf( &psz_manifest_uri, "%s!/manifest.xml", psz_tempfileuri ) < 1 )
+ if ( asprintf( &psz_manifest_uri, "%s#!/manifest.xml", psz_tempfileuri ) < 1 )
{
free( psz_tempfileuri );
return VLC_ENOMEM;
}
- p_stream = vlc_stream_NewURL( p_finder, psz_manifest_uri );
+ p_stream = vlc_stream_NewMRL( p_finder, psz_manifest_uri );
free( psz_manifest_uri );
if ( !p_stream )
{
@@ -457,11 +457,11 @@ static int FindDesignated( addons_finder_t *p_finder )
char *psz_manifest;
const char *psz_path = p_finder->psz_uri + 7; // remove scheme
- if ( asprintf( &psz_manifest, "unzip://%s!/manifest.xml",
+ if ( asprintf( &psz_manifest, "file://%s#!/manifest.xml",
psz_path ) < 1 )
return VLC_ENOMEM;
- stream_t *p_stream = vlc_stream_NewURL( p_finder, psz_manifest );
+ stream_t *p_stream = vlc_stream_NewMRL( p_finder, psz_manifest );
free( psz_manifest );
if ( !p_stream ) return VLC_EGENERIC;
--
2.12.0
More information about the vlc-devel
mailing list