From: Tim-Philipp Müller Date: Sun, 29 May 2011 12:32:04 +0000 (+0100) Subject: tests: fix some more unused-but-set-variable warnings with gcc 4.6 X-Git-Tag: 1.19.3~511^2~6555^2~829 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4f6da2bcbc99e12940911f68d906861890e2304b;p=platform%2Fupstream%2Fgstreamer.git tests: fix some more unused-but-set-variable warnings with gcc 4.6 --- diff --git a/tests/check/elements/adder.c b/tests/check/elements/adder.c index eadf31d..32a085f 100644 --- a/tests/check/elements/adder.c +++ b/tests/check/elements/adder.c @@ -573,7 +573,6 @@ GST_START_TEST (test_add_pad) GstElement *bin, *src1, *src2, *adder, *sink; GstBus *bus; GstPad *srcpad; - GstStreamConsistency *consist; gboolean res; GST_INFO ("preparing test"); @@ -600,7 +599,6 @@ GST_START_TEST (test_add_pad) fail_unless (res == TRUE, NULL); srcpad = gst_element_get_static_pad (adder, "src"); - consist = gst_consistency_checker_new (srcpad); gst_object_unref (srcpad); main_loop = g_main_loop_new (NULL, FALSE); @@ -656,7 +654,6 @@ GST_START_TEST (test_remove_pad) GstBus *bus; GstPad *pad, *srcpad; gboolean res; - GstStreamConsistency *consist; GST_INFO ("preparing test"); @@ -682,7 +679,6 @@ GST_START_TEST (test_remove_pad) fail_if (pad == NULL, NULL); srcpad = gst_element_get_static_pad (adder, "src"); - consist = gst_consistency_checker_new (srcpad); gst_object_unref (srcpad); main_loop = g_main_loop_new (NULL, FALSE); diff --git a/tests/check/elements/ffmpegcolorspace.c b/tests/check/elements/ffmpegcolorspace.c index 60179c6..8721a8c 100644 --- a/tests/check/elements/ffmpegcolorspace.c +++ b/tests/check/elements/ffmpegcolorspace.c @@ -174,7 +174,7 @@ check_rgb_buf (const guint8 * pixels, guint32 r_mask, guint32 g_mask, guint32 b_mask, guint32 a_mask, guint8 r_expected, guint8 g_expected, guint8 b_expected, guint endianness, guint bpp, guint depth) { - guint32 pixel, red, green, blue, alpha; + guint32 pixel, red, green, blue; switch (bpp) { case 32:{ @@ -210,7 +210,7 @@ check_rgb_buf (const guint8 * pixels, guint32 r_mask, guint32 g_mask, red = right_shift_colour (r_mask, pixel); green = right_shift_colour (g_mask, pixel); blue = right_shift_colour (b_mask, pixel); - alpha = right_shift_colour (a_mask, pixel); + /* alpha = right_shift_colour (a_mask, pixel); */ /* can't enable this by default, valgrind will complain about accessing * uninitialised memory for the depth=24,bpp=32 formats ... */ diff --git a/tests/check/elements/vorbistag.c b/tests/check/elements/vorbistag.c index 4b20d6d..bb05236 100644 --- a/tests/check/elements/vorbistag.c +++ b/tests/check/elements/vorbistag.c @@ -192,7 +192,7 @@ _create_audio_buffer (void) { GstBuffer *buffer; ogg_packet packet; - float **vorbis_buffer; + float **vorbis_buffer G_GNUC_UNUSED; vorbis_buffer = vorbis_analysis_buffer (&vd, 0); vorbis_analysis_wrote (&vd, 0); diff --git a/tests/check/libs/rtp.c b/tests/check/libs/rtp.c index defd6b6..68c4535 100644 --- a/tests/check/libs/rtp.c +++ b/tests/check/libs/rtp.c @@ -635,12 +635,10 @@ GST_START_TEST (test_rtcp_buffer) { GstBuffer *buf; GstRTCPPacket packet; - guint8 *data; buf = gst_rtcp_buffer_new (1400); fail_unless (buf != NULL); fail_unless_equals_int (GST_BUFFER_SIZE (buf), 1400); - data = GST_BUFFER_DATA (buf); fail_unless (gst_rtcp_buffer_get_first_packet (buf, &packet) == FALSE); fail_unless (gst_rtcp_buffer_get_packet_count (buf) == 0); diff --git a/tests/check/pipelines/theoraenc.c b/tests/check/pipelines/theoraenc.c index ddc37d6..3b101d0 100644 --- a/tests/check/pipelines/theoraenc.c +++ b/tests/check/pipelines/theoraenc.c @@ -272,7 +272,6 @@ GST_START_TEST (test_continuity) { GstClockTime next_timestamp; - gint64 last_granulepos; /* first buffer should have timestamp of TIMESTAMP_OFFSET, granulepos to * match the timestamp of the end of the last sample in the output buffer. @@ -281,7 +280,6 @@ GST_START_TEST (test_continuity) * take care to timestamp correctly based on the offset of the input data * however, so it does do sub-granulepos timestamping. */ buffer = gst_buffer_straw_get_buffer (bin, pad); - last_granulepos = GST_BUFFER_OFFSET_END (buffer); check_buffer_timestamp (buffer, 0); /* plain division because I know the answer is exact */ check_buffer_duration (buffer, GST_SECOND / 10);