From: Tim-Philipp Müller Date: Mon, 24 Jun 2019 09:42:31 +0000 (+0000) Subject: v4l2: fix compiler warning due to c99-ism X-Git-Tag: 1.19.3~509^2~990 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=92e4ecef4caa09f0caa83a8440d0d641b75f9e2f;p=platform%2Fupstream%2Fgstreamer.git v4l2: fix compiler warning due to c99-ism --- diff --git a/sys/v4l2/gstv4l2codec.c b/sys/v4l2/gstv4l2codec.c index 696ba3c..7ebc650 100644 --- a/sys/v4l2/gstv4l2codec.c +++ b/sys/v4l2/gstv4l2codec.c @@ -106,11 +106,13 @@ gst_v4l2_codec_probe_levels (const GstV4l2Codec * codec, gint video_fd) query_menu.index = query_ctrl.maximum; if (ioctl (video_fd, VIDIOC_QUERYMENU, &query_menu) >= 0) { + gint32 i; + controls = g_new0 (GValue, 1); g_value_init (controls, GST_TYPE_LIST); /* Assume that all levels below the highest one reported by the driver are supported. */ - for (gint32 i = query_ctrl.minimum; i <= query_ctrl.maximum; i++) { + for (i = query_ctrl.minimum; i <= query_ctrl.maximum; i++) { GValue value = G_VALUE_INIT; g_value_init (&value, G_TYPE_STRING);