Commit 270b1511 authored by Laurent Aimar's avatar Laurent Aimar

* demux2, access2: prototype change.

parent 65fd1e94
......@@ -102,28 +102,13 @@ static int Access2Open( vlc_object_t * p_this )
access2_sys_t *p_sys = malloc( sizeof( access2_sys_t ) );
access_t *p_access;
char *psz_uri;
int i_int;
int64_t i_64;
vlc_bool_t b_bool;
psz_uri = malloc( strlen( p_input->psz_access ) + strlen( p_input->psz_demux ) + strlen( p_input->psz_name ) + 1 + 3 + 1 );
if( p_input->psz_demux && *p_input->psz_demux )
{
sprintf( psz_uri, "%s/%s://%s", p_input->psz_access, p_input->psz_demux, p_input->psz_name );
}
else if( p_input->psz_access && *p_input->psz_access )
{
sprintf( psz_uri, "%s://%s", p_input->psz_access, p_input->psz_name );
}
else
{
sprintf( psz_uri, "://%s", p_input->psz_name );
}
p_access = access2_New( p_input, psz_uri );
free( psz_uri );
p_access = access2_New( p_input,
p_input->psz_access, p_input->psz_demux,
p_input->psz_name );
if( !p_access )
{
......
......@@ -94,30 +94,15 @@ static int Demux2Open( vlc_object_t * p_this )
demux_t *p_demux;
playlist_t *p_playlist;
char *psz_uri;
if( input_InitStream( p_input, 0 ) )
{
return VLC_EGENERIC;
}
psz_uri = malloc( strlen( p_input->psz_access ) + strlen( p_input->psz_demux ) + strlen( p_input->psz_name ) + 1 + 3 + 1 );
if( p_input->psz_demux && *p_input->psz_demux )
{
sprintf( psz_uri, "%s/%s://%s", p_input->psz_access, p_input->psz_demux, p_input->psz_name );
}
else if( p_input->psz_access && *p_input->psz_access )
{
sprintf( psz_uri, "%s://%s", p_input->psz_access, p_input->psz_name );
}
else
{
sprintf( psz_uri, "://%s", p_input->psz_name );
}
p_demux = demux2_New( p_input, psz_uri, p_input->s, p_input->p_es_out );
free( psz_uri );
p_demux = demux2_New( p_input,
p_input->psz_access, p_input->psz_demux,
p_input->psz_name,
p_input->s, p_input->p_es_out );
if( !p_demux )
{
......
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