glcolorconvert: fix compiler warning
authorTim-Philipp Müller <tim@centricular.com>
Tue, 27 May 2014 12:56:34 +0000 (13:56 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Tue, 27 May 2014 12:57:18 +0000 (13:57 +0100)
gstglcolorconvert.c:1133:11: error: 'j' may be used uninitialized in this function

Was used uninitialized when jumping to out label
in error case.

gst-libs/gst/gl/gstglcolorconvert.c

index f97d37c..246bb6e 100644 (file)
@@ -1130,7 +1130,7 @@ _do_convert (GstGLContext * context, GstGLColorConvert * convert)
   struct ConvertInfo *c_info = &convert->priv->convert_info;
   GstMapInfo out_info[GST_VIDEO_MAX_PLANES], in_info[GST_VIDEO_MAX_PLANES];
   gboolean res = TRUE;
-  gint i, j;
+  gint i, j = 0;
 
   out_width = GST_VIDEO_INFO_WIDTH (&convert->out_info);
   out_height = GST_VIDEO_INFO_HEIGHT (&convert->out_info);