]> git.sesse.net Git - vlc/blobdiff - modules/mux/mp4.c
Qt: Add a parent to the CoverArtLabel We should add parents to all QWidgets created...
[vlc] / modules / mux / mp4.c
index eb50dbfc055e22258da432c1058b3be46714af68..ab8526f98a1113f31d5b3ac141e6727b2ca0b89f 100644 (file)
@@ -193,6 +193,8 @@ static int Open( vlc_object_t *p_this )
     p_mux->pf_delstream = DelStream;
     p_mux->pf_mux       = Mux;
     p_mux->p_sys        = p_sys = malloc( sizeof( sout_mux_sys_t ) );
+    if( !p_sys )
+        return VLC_ENOMEM;
     p_sys->i_pos        = 0;
     p_sys->i_nb_streams = 0;
     p_sys->pp_streams   = NULL;
@@ -422,6 +424,8 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
     }
 
     p_stream                = malloc( sizeof( mp4_stream_t ) );
+    if( !p_stream )
+        return VLC_ENOMEM;
     es_format_Copy( &p_stream->fmt, p_input->p_fmt );
     p_stream->i_track_id    = p_sys->i_nb_streams + 1;
     p_stream->i_length_neg  = 0;
@@ -1533,7 +1537,7 @@ static bo_t *GetStblBox( sout_mux_t *p_mux, mp4_stream_t *p_stream )
 
 static int64_t get_timestamp(void);
 
-static uint32_t mvhd_matrix[9] =
+static const uint32_t mvhd_matrix[9] =
     { 0x10000, 0, 0, 0, 0x10000, 0, 0, 0, 0x40000000 };
 
 static bo_t *GetMoovBox( sout_mux_t *p_mux )
@@ -2130,6 +2134,7 @@ static void box_gather ( bo_t *box, bo_t *box2 )
 
 static block_t * bo_to_sout( sout_instance_t *p_sout,  bo_t *box )
 {
+    (void)p_sout;
     block_t *p_buf;
 
     p_buf = block_New( p_sout, box->i_buffer );