]> git.sesse.net Git - vlc/blobdiff - src/input/es_out.c
es_out: use input_DecoderDrain()
[vlc] / src / input / es_out.c
index b2326435e9923971fbc862425f8078a860a0347c..ec7d6556ccd2ae830aeaf7f58969bcc79c3a8721 100644 (file)
@@ -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;
     }