gst: Fix unintialized variable warnings
authorVíctor Manuel Jáquez Leal <vjaquez@igalia.com>
Mon, 25 Jan 2016 16:21:24 +0000 (17:21 +0100)
committerSebastian Dröge <sebastian@centricular.com>
Wed, 27 Jan 2016 12:46:07 +0000 (13:46 +0100)
While cross-compiling with Linaro GCC 5.1-2015.08, it complained
about a couple unitialized variables.

This patch initializes them to zero.

https://bugzilla.gnome.org/show_bug.cgi?id=761094

gst/isomp4/qtdemux.c
gst/rtp/gstrtph261pay.c

index 77bb73e8d95635ac5c1e82b3b54e9027b0fafca4..1aaafa86195c00a383d16da7ef1fdbbf8d7624cf 100644 (file)
@@ -3245,7 +3245,7 @@ qtdemux_parse_cenc_aux_info (GstQTDemux * qtdemux, QtDemuxStream * stream,
 
   for (i = 0; i < sample_count; ++i) {
     GstStructure *properties;
-    guint16 n_subsamples;
+    guint16 n_subsamples = 0;
     guint8 *data;
     guint iv_size;
     GstBuffer *buf;
index 7cdd323929a24ac3095d82a41fa4961db27a54cc..ebcf80e4a2fa8a3a6d207e61eb7ab00e99b7aa72 100644 (file)
@@ -867,7 +867,7 @@ gst_rtp_h261_packetize_and_push (GstRtpH261Pay * pay, GstBuffer * buffer,
       gst_rtp_buffer_calc_payload_len (GST_RTP_BASE_PAYLOAD_MTU (pay) -
       GST_RTP_H261_PAYLOAD_HEADER_LEN, 0, 0);
   guint startpos;
-  gint num_gobs;
+  gint num_gobs = 0;
   Gob gobs[MAX_NUM_GOB];
   Gob *gob;
   Macroblock last_mb_in_previous_packet = { 0 };