Commit 91c5dd59 authored by Gildas Bazin's avatar Gildas Bazin

* src/input/decoder.c: better pictures leakage detection.

parent 1e9c67a5
......@@ -783,13 +783,18 @@ static picture_t *vout_new_buffer( decoder_t *p_dec )
for( i_pic = 0; i_pic < p_dec->p_owner->p_vout->render.i_pictures;
i_pic++ )
{
if( p_pic->i_status == READY_PICTURE && i_ready_pic++ > 0 ) break;
if( p_pic->i_status == READY_PICTURE )
{
if( i_ready_pic++ > 0 ) break;
else continue;
}
if( p_pic->i_status != DISPLAYED_PICTURE &&
p_pic->i_status != RESERVED_PICTURE &&
p_pic->i_status != READY_PICTURE ) break;
if( !p_pic->i_refcount ) break;
if( !p_pic->i_refcount && p_pic->i_status != RESERVED_PICTURE )
break;
}
if( i_pic == p_dec->p_owner->p_vout->render.i_pictures )
{
......
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