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

Get input length from metadata if demuxer failed to retrieve it

parent 55f5d1da
......@@ -904,6 +904,12 @@ static int Init( input_thread_t * p_input )
var_Change( p_input, "length", VLC_VAR_SETVALUE, &val, NULL );
UpdateItemLength( p_input, val.i_time );
}
else if( p_input->p->input.p_item->i_duration > 0)
{
val.i_time = p_input->p->input.p_item->i_duration;
var_Change( p_input, "length", VLC_VAR_SETVALUE, &val, NULL );
UpdateItemLength( p_input, val.i_time );
}
/* Start title/chapter */
if( !p_input->b_preparsing )
......
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