Cleanup input stats when sout fails
authorRémi Denis-Courmont <rdenis@simphalempin.com>
Wed, 11 Feb 2009 20:41:02 +0000 (22:41 +0200)
committerRémi Denis-Courmont <rdenis@simphalempin.com>
Wed, 11 Feb 2009 21:12:35 +0000 (23:12 +0200)
src/input/input.c

index 4d2ac51..49abe70 100644 (file)
@@ -1142,7 +1142,7 @@ static int Init( input_thread_t * p_input )
 #ifdef ENABLE_SOUT
     ret = InitSout( p_input );
     if( ret != VLC_SUCCESS )
-        return ret; /* FIXME: goto error; should be better here */
+        goto error_stats;
 #endif
 
     /* Create es out */
@@ -1240,6 +1240,9 @@ error:
         input_ressource_SetInput( p_input->p->p_ressource, NULL );
     }
 
+#ifdef ENABLE_SOUT
+error_stats:
+#endif
     if( !p_input->b_preparsing && libvlc_stats( p_input ) )
     {
 #define EXIT_COUNTER( c ) do { if( p_input->p->counters.p_##c ) \