From 3342d86d9b92cf60c419b728d10944968d77ecac Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Wed, 5 Apr 2017 09:46:31 -0400 Subject: [PATCH] v4l2videodec: Fix 32bit only printf format The previous patch was using %llu for 64bits printf, which is 32bit specific. We also trace the latency in time human readable form now. --- sys/v4l2/gstv4l2videodec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/v4l2/gstv4l2videodec.c b/sys/v4l2/gstv4l2videodec.c index 8f713b6..2d5fea6 100644 --- a/sys/v4l2/gstv4l2videodec.c +++ b/sys/v4l2/gstv4l2videodec.c @@ -753,9 +753,10 @@ gst_v4l2_video_dec_decide_allocation (GstVideoDecoder * decoder, query); if (GST_CLOCK_TIME_IS_VALID (self->v4l2capture->duration)) { - GST_DEBUG_OBJECT (self, "Setting latency: %u * %llu", - self->v4l2capture->min_buffers, self->v4l2capture->duration); latency = self->v4l2capture->min_buffers * self->v4l2capture->duration; + GST_DEBUG_OBJECT (self, "Setting latency: %" GST_TIME_FORMAT " (%" + G_GUINT32_FORMAT " * %" G_GUINT64_FORMAT, GST_TIME_ARGS (latency), + self->v4l2capture->min_buffers, self->v4l2capture->duration); gst_video_decoder_set_latency (decoder, latency, latency); } else { GST_WARNING_OBJECT (self, "Duration invalid, not setting latency"); -- 2.7.4