Commit 9b978809 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Fix port release logic in case there are multiple channels.

Note however that releasing the "other" ports is still broken.
Signed-off-by: default avatarRémi Denis-Courmont <rem@videolan.org>
parent a49951f4
......@@ -1209,13 +1209,10 @@ static int Del( sout_stream_t *p_stream, sout_stream_id_t *id )
vlc_mutex_unlock( &p_sys->lock_es );
/* Release port */
if( id->i_port > 0 )
{
if( id->i_cat == AUDIO_ES && p_sys->i_port_audio == 0 )
p_sys->i_port_audio = id->i_port;
else if( id->i_cat == VIDEO_ES && p_sys->i_port_video == 0 )
p_sys->i_port_video = id->i_port;
}
if( id->i_port == var_GetInteger( p_stream, "port-audio" ) )
p_sys->i_port_audio = id->i_port;
if( id->i_port == var_GetInteger( p_stream, "port-video" ) )
p_sys->i_port_video = id->i_port;
free( id->psz_fmtp );
......
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