From 4e59e63ff7c3d32b2a81ec52a6825ed00471eec4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Wed, 19 Oct 2011 00:32:13 +0100 Subject: [PATCH] baseaudiosink: fix unused variable compiler warning if debugging in core is disabled https://bugzilla.gnome.org/show_bug.cgi?id=660150 --- gst-libs/gst/audio/gstbaseaudiosink.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gst-libs/gst/audio/gstbaseaudiosink.c b/gst-libs/gst/audio/gstbaseaudiosink.c index 6dafb4b322..a7477508e4 100644 --- a/gst-libs/gst/audio/gstbaseaudiosink.c +++ b/gst-libs/gst/audio/gstbaseaudiosink.c @@ -1367,9 +1367,11 @@ gst_base_audio_sink_get_alignment (GstBaseAudioSink * sink, "align with prev sample, ABS (%" G_GINT64_FORMAT ") < %" G_GINT64_FORMAT, align, maxdrift); } else { + gint64 diff_s G_GNUC_UNUSED; + /* calculate sample diff in seconds for error message */ - gint64 diff_s = gst_util_uint64_scale_int (diff, GST_SECOND, - ringbuf->spec.rate); + diff_s = gst_util_uint64_scale_int (diff, GST_SECOND, ringbuf->spec.rate); + /* timestamps drifted apart from previous samples too much, we need to * resync. We log this as an element warning. */ GST_WARNING_OBJECT (sink,