]> git.sesse.net Git - vlc/blobdiff - src/stream_output/stream_output.c
Remove not used allocation added in [bc650c59ca6d2edbf555dc0cec11091f274b42f5]
[vlc] / src / stream_output / stream_output.c
index 8f4a76a1b7f29dae12c53a7f783e8a3893788a92..ea5bee8e904570cad578a58640866bbdb6f0e570 100644 (file)
@@ -92,7 +92,7 @@ sout_instance_t *__sout_NewInstance( vlc_object_t *p_parent, char * psz_dest )
     p_sout->i_out_pace_nocontrol = 0;
     p_sout->p_sys       = NULL;
 
-    vlc_mutex_init( p_sout, &p_sout->lock );
+    vlc_mutex_init( &p_sout->lock );
     if( psz_dest && psz_dest[0] == '#' )
     {
         p_sout->psz_chain = strdup( &psz_dest[1] );
@@ -160,7 +160,7 @@ void sout_UpdateStatistic( sout_instance_t *p_sout, sout_statistic_t i_type, int
     int i_bytes; /* That's pretty stupid to define it as an integer, it will overflow
                     really fast ... */
 
-    if( !p_sout->p_libvlc->b_stats )
+    if( !libvlc_stats (p_sout) )
         return;
 
     /* FIXME that's ugly
@@ -214,6 +214,7 @@ sout_packetizer_input_t *sout_InputNew( sout_instance_t *p_sout,
 
     /* *** create a packetizer input *** */
     p_input         = malloc( sizeof( sout_packetizer_input_t ) );
+    if( !p_input )  return NULL;
     p_input->p_sout = p_sout;
     p_input->p_fmt  = p_fmt;
 
@@ -530,7 +531,7 @@ sout_input_t *sout_MuxAddStream( sout_mux_t *p_mux, es_format_t *p_fmt )
     }
     p_input->p_sout = p_mux->p_sout;
     p_input->p_fmt  = p_fmt;
-    p_input->p_fifo = block_FifoNew( p_mux->p_sout );
+    p_input->p_fifo = block_FifoNew();
     p_input->p_sys  = NULL;
 
     TAB_APPEND( p_mux->i_nb_inputs, p_mux->pp_inputs, p_input );
@@ -761,41 +762,6 @@ static void mrl_Clean( mrl_t *p_mrl )
  *  return a pointer on the rest
  *  XXX: psz_chain is modified
  */
-#define SKIPSPACE( p ) { while( *p && ( *p == ' ' || *p == '\t' ) ) p++; }
-#define SKIPTRAILINGSPACE( p, e ) \
-    { while( e > p && ( *(e-1) == ' ' || *(e-1) == '\t' ) ) e--; }
-
-/* go accross " " and { } */
-static char *_get_chain_end( char *str )
-{
-    char c, *p = str;
-
-    SKIPSPACE( p );
-
-    for( ;; )
-    {
-        if( !*p || *p == ',' || *p == '}' ) return p;
-
-        if( *p != '{' && *p != '"' && *p != '\'' )
-        {
-            p++;
-            continue;
-        }
-
-        if( *p == '{' ) c = '}';
-        else c = *p;
-        p++;
-
-        for( ;; )
-        {
-            if( !*p ) return p;
-
-            if( *p == c ) return ++p;
-            else if( *p == '{' && c == '}' ) p = _get_chain_end( p );
-            else p++;
-        }
-    }
-}
 
 /*
  * XXX name and p_cfg are used (-> do NOT free them)