v4l2videodec: Fix 32bit only printf format
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Wed, 5 Apr 2017 13:46:31 +0000 (09:46 -0400)
committerNicolas Dufresne <nicolas.dufresne@collabora.com>
Wed, 5 Apr 2017 13:46:31 +0000 (09:46 -0400)
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

index 8f713b6..2d5fea6 100644 (file)
@@ -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");