Commit d1ad603d authored by Rafaël Carré's avatar Rafaël Carré

bluray: free resource as soon as not needed

parent 695029cd
...@@ -1303,12 +1303,12 @@ static void blurayHandleEvent( demux_t *p_demux, const BD_EVENT *e ) ...@@ -1303,12 +1303,12 @@ static void blurayHandleEvent( demux_t *p_demux, const BD_EVENT *e )
break ; break ;
/* The param we get is the real stream id, not an index, ie. it starts from 1 */ /* The param we get is the real stream id, not an index, ie. it starts from 1 */
int pid = info->clips[p_sys->i_current_clip].audio_streams[e->param - 1].pid; int pid = info->clips[p_sys->i_current_clip].audio_streams[e->param - 1].pid;
bd_free_title_info( info );
int idx = findEsPairIndex(p_sys, pid); int idx = findEsPairIndex(p_sys, pid);
if (idx >= 0) { if (idx >= 0) {
es_out_id_t *p_es = vlc_array_item_at_index(&p_sys->es, idx); es_out_id_t *p_es = vlc_array_item_at_index(&p_sys->es, idx);
es_out_Control( p_demux->out, ES_OUT_SET_ES, p_es ); es_out_Control( p_demux->out, ES_OUT_SET_ES, p_es );
} }
bd_free_title_info( info );
p_sys->i_audio_stream = pid; p_sys->i_audio_stream = pid;
break ; break ;
case BD_EVENT_CHAPTER: case BD_EVENT_CHAPTER:
......
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