[vlc-commits] es_out: assert single block on es_out_Send()

Rémi Denis-Courmont git at videolan.org
Tue Nov 28 17:42:11 CET 2017


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Mon Nov 27 19:15:17 2017 +0200| [7c898da4262adf468cdd0f9edc71095a27e4bf8b] | committer: Rémi Denis-Courmont

es_out: assert single block on es_out_Send()

The handling code ostensibly assumes that the block is single. So this
adds an assertion to ensure it.

Alternatively, should we force p_next to NULL ?

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7c898da4262adf468cdd0f9edc71095a27e4bf8b
---

 src/input/es_out.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/input/es_out.c b/src/input/es_out.c
index 07f118b2ce..c4a848d5e9 100644
--- a/src/input/es_out.c
+++ b/src/input/es_out.c
@@ -2039,6 +2039,8 @@ static int EsOutSend( es_out_t *out, es_out_id_t *es, block_t *p_block )
     es_out_sys_t   *p_sys = out->p_sys;
     input_thread_t *p_input = p_sys->p_input;
 
+    assert( p_block->p_next == NULL );
+
     if( libvlc_stats( p_input ) )
     {
         uint64_t i_total;



More information about the vlc-commits mailing list