From fb0add8f258a63019d72f73b03d43a62f5effdd6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?R=C3=A9mi=20Denis-Courmont?= Date: Sat, 21 Mar 2015 19:09:45 +0200 Subject: [PATCH] es_out: use input_DecoderDrain() --- src/input/es_out.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/src/input/es_out.c b/src/input/es_out.c index b2326435e9..ec7d6556cc 100644 --- a/src/input/es_out.c +++ b/src/input/es_out.c @@ -2684,15 +2684,8 @@ static int EsOutControlLocked( es_out_t *out, int i_query, va_list args ) { for (int i = 0; i < p_sys->i_es; i++) { es_out_id_t *id = p_sys->es[i]; - decoder_t *p_dec = id->p_dec; - if (!p_dec) - continue; - block_t *p_block = block_Alloc(0); - if( !p_block ) - break; - - p_block->i_flags |= BLOCK_FLAG_CORE_EOS; - input_DecoderDecode(p_dec, p_block, false); + if (id->p_dec != NULL) + input_DecoderDrain(id->p_dec); } return VLC_SUCCESS; } -- 2.39.2