Fixed record DelEs function.
authorLaurent Aimar <fenrir@videolan.org>
Mon, 27 Apr 2009 18:24:59 +0000 (20:24 +0200)
committerLaurent Aimar <fenrir@videolan.org>
Tue, 28 Apr 2009 16:59:41 +0000 (18:59 +0200)
It fixes some segfault when stopping recording.

modules/stream_out/record.c

index ed5b2f3..53a3f39 100644 (file)
@@ -210,12 +210,13 @@ static int Del( sout_stream_t *p_stream, sout_stream_id_t *id )
 
     if( id->p_first )
         block_ChainRelease( id->p_first );
-    es_format_Clean( &id->fmt );
 
     assert( !id->id || p_sys->p_out );
     if( id->id )
         sout_StreamIdDel( p_sys->p_out, id->id );
 
+    es_format_Clean( &id->fmt );
+
     TAB_REMOVE( p_sys->i_id, p_sys->id, id );
 
     if( p_sys->i_id <= 0 )