filesink, filesrc: printf format fixes
authorTim-Philipp Müller <tim.muller@collabora.co.uk>
Thu, 3 Dec 2009 20:53:25 +0000 (20:53 +0000)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Thu, 3 Dec 2009 20:53:25 +0000 (20:53 +0000)
gstfilesink.c:399: error: format ‘%d’ expects type ‘int’, but argument 8 has type ‘size_t’
gstfilesink.c:399: error: format ‘%d’ expects type ‘int’, but argument 9 has type ‘gsize’
gstfilesrc.c:588: error: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 8 has type ‘off_t’

plugins/elements/gstfilesink.c
plugins/elements/gstfilesrc.c

index d2ad8b5..47e5982 100644 (file)
@@ -381,7 +381,7 @@ gst_file_sink_open_file (GstFileSink * sink)
 
   /* see if we are asked to perform a specific kind of buffering */
   if ((mode = sink->buffer_mode) != -1) {
-    gsize buffer_size;
+    guint buffer_size;
 
     /* free previous buffer if any */
     g_free (sink->buffer);
@@ -396,10 +396,10 @@ gst_file_sink_open_file (GstFileSink * sink)
       buffer_size = sink->buffer_size;
     }
 #ifdef HAVE_STDIO_EXT_H
-    GST_DEBUG_OBJECT (sink, "change buffer size %d to %d, mode %d",
-        __fbufsize (sink->file), buffer_size, mode);
+    GST_DEBUG_OBJECT (sink, "change buffer size %u to %u, mode %d",
+        (guint) __fbufsize (sink->file), buffer_size, mode);
 #else
-    GST_DEBUG_OBJECT (sink, "change  buffer size to %d, mode %d",
+    GST_DEBUG_OBJECT (sink, "change  buffer size to %u, mode %d",
         sink->buffer_size, mode);
 #endif
     if (setvbuf (sink->file, sink->buffer, mode, buffer_size) != 0) {
index 03f5249..d69167a 100644 (file)
@@ -585,8 +585,8 @@ gst_file_src_map_region (GstFileSrc * src, off_t offset, gsize size,
 
   g_return_val_if_fail (offset >= 0, NULL);
 
-  GST_LOG_OBJECT (src, "mapping region %08llx+%08lx from file into memory",
-      offset, (gulong) size);
+  GST_LOG_OBJECT (src, "mapping region %08" G_GOFFSET_MODIFIER "x+%08lx "
+      "from file into memory", (goffset) offset, (gulong) size);
 
   mmapregion = mmap (NULL, size, PROT_READ, MAP_SHARED, src->fd, offset);