[vlc-commits] input: Ensure stats counters are released when changing sout

Hugo Beauzée-Luyssen git at videolan.org
Tue Sep 19 11:49:03 CEST 2017


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Thu Sep  7 18:38:48 2017 +0200| [53c06cf4b1fba3106fdf48dbc931215d43888943] | committer: Hugo Beauzée-Luyssen

input: Ensure stats counters are released when changing sout

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

 src/input/input.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/input/input.c b/src/input/input.c
index 94413449f6..542aa51475 100644
--- a/src/input/input.c
+++ b/src/input/input.c
@@ -803,7 +803,8 @@ static void InitStatistics( input_thread_t *p_input )
     if( priv->b_preparsing ) return;
 
     /* Prepare statistics */
-#define INIT_COUNTER( c, compute ) priv->counters.p_##c = \
+#define INIT_COUNTER( c, compute ) free( priv->counters.p_##c ); \
+    priv->counters.p_##c = \
  stats_CounterCreate( STATS_##compute);
     if( libvlc_stats( p_input ) )
     {



More information about the vlc-commits mailing list