Fix printf format compiler warnings on OS X / 64 bit

https://bugzilla.gnome.org/show_bug.cgi?id=662618
This commit is contained in:
Matej Knopp 2011-11-21 22:45:15 +01:00 committed by Tim-Philipp Müller
parent 0a9387c43c
commit 9d0bdcf6d7
8 changed files with 34 additions and 27 deletions

View file

@ -307,7 +307,7 @@ GST_PLUGINS_NONPORTED=" adpcmdec adpcmenc aiff asfmux \
voaacenc apexsink bz2 camerabin2 cdaudio celt cog curl dc1394 dirac directfb dts resindvd \
gsettings gsm jp2k ladspa modplug mpeg2enc mplex mimic \
musepack musicbrainz nas neon ofa openal rsvg schro sdl smooth sndfile soundtouch spandsp timidity \
wildmidi xvid "
wildmidi xvid apple_media "
AC_SUBST(GST_PLUGINS_NONPORTED)
dnl these are all the gst plug-ins, compilable without additional libs

View file

@ -1151,7 +1151,7 @@ gst_base_video_decoder_flush_parse (GstBaseVideoDecoder * dec)
GstBuffer *buf = GST_BUFFER_CAST (dec->queued->data);
if (G_LIKELY (res == GST_FLOW_OK)) {
GST_DEBUG_OBJECT (dec, "pushing buffer %p of size %u, "
GST_DEBUG_OBJECT (dec, "pushing buffer %p of size %" G_GSIZE_FORMAT ", "
"time %" GST_TIME_FORMAT ", dur %" GST_TIME_FORMAT, buf,
gst_buffer_get_size (buf), GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)));
@ -1194,7 +1194,7 @@ gst_base_video_decoder_chain_reverse (GstBaseVideoDecoder * dec,
}
if (G_LIKELY (buf)) {
GST_DEBUG_OBJECT (dec, "gathering buffer %p of size %u, "
GST_DEBUG_OBJECT (dec, "gathering buffer %p of size %" G_GSIZE_FORMAT ", "
"time %" GST_TIME_FORMAT ", dur %" GST_TIME_FORMAT, buf,
gst_buffer_get_size (buf), GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)));
@ -1215,8 +1215,8 @@ gst_base_video_decoder_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
base_video_decoder = GST_BASE_VIDEO_DECODER (parent);
GST_LOG_OBJECT (base_video_decoder,
"chain %" GST_TIME_FORMAT " duration %" GST_TIME_FORMAT " size %d",
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
"chain %" GST_TIME_FORMAT " duration %" GST_TIME_FORMAT " size %"
G_GSIZE_FORMAT "", GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)), gst_buffer_get_size (buf));
GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
@ -1374,7 +1374,8 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
#ifndef GST_DISABLE_GST_DEBUG
GST_LOG_OBJECT (base_video_decoder, "n %d in %d out %d",
GST_LOG_OBJECT (base_video_decoder,
"n %d in %" G_GSIZE_FORMAT " out %" G_GSIZE_FORMAT,
g_list_length (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames),
gst_adapter_available (base_video_decoder->input_adapter),
gst_adapter_available (base_video_decoder->output_adapter));

View file

@ -715,7 +715,7 @@ gst_base_video_encoder_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
GST_LOG_OBJECT (base_video_encoder,
"received buffer of size %d with ts %" GST_TIME_FORMAT
"received buffer of size %" G_GSIZE_FORMAT " with ts %" GST_TIME_FORMAT
", duration %" GST_TIME_FORMAT, gst_buffer_get_size (buf),
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)));

View file

@ -710,7 +710,8 @@ gst_dvbsub_overlay_process_text (GstDVBSubOverlay * overlay, GstBuffer * buffer,
"Processing subtitles with fake PTS=%" G_GUINT64_FORMAT
" which is a running time of %" GST_TIME_FORMAT,
pts, GST_TIME_ARGS (pts));
GST_DEBUG_OBJECT (overlay, "Feeding %u bytes to libdvbsub", size);
GST_DEBUG_OBJECT (overlay, "Feeding %" G_GSIZE_FORMAT " bytes to libdvbsub",
size);
data = gst_buffer_map (buffer, &size, NULL, GST_MAP_READ);
@ -748,7 +749,8 @@ gst_dvbsub_overlay_chain_text (GstPad * pad, GstObject * parent,
GstDVBSubOverlay *overlay = GST_DVBSUB_OVERLAY (parent);
GstClockTime sub_running_time;
GST_INFO_OBJECT (overlay, "subpicture/x-dvb buffer with size %u",
GST_INFO_OBJECT (overlay,
"subpicture/x-dvb buffer with size %" G_GSIZE_FORMAT,
gst_buffer_get_size (buffer));
GST_LOG_OBJECT (overlay,

View file

@ -829,8 +829,9 @@ submit_new_spu_packet (GstDVDSpu * dvdspu, GstBuffer * buf)
GstClockTime run_ts = GST_CLOCK_TIME_NONE;
GST_DEBUG_OBJECT (dvdspu,
"Complete subpicture buffer of %u bytes with TS %" GST_TIME_FORMAT,
gst_buffer_get_size (buf), GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)));
"Complete subpicture buffer of %" G_GSIZE_FORMAT " bytes with TS %"
GST_TIME_FORMAT, gst_buffer_get_size (buf),
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)));
/* Decide whether to pass this buffer through to the rendering code */
ts = GST_BUFFER_TIMESTAMP (buf);
@ -886,7 +887,7 @@ gst_dvd_spu_subpic_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
g_return_val_if_fail (dvdspu != NULL, GST_FLOW_ERROR);
GST_INFO_OBJECT (dvdspu, "Have subpicture buffer with timestamp %"
GST_TIME_FORMAT " and size %u",
GST_TIME_FORMAT " and size %" G_GSIZE_FORMAT,
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)), gst_buffer_get_size (buf));
DVD_SPU_LOCK (dvdspu);
@ -933,15 +934,15 @@ gst_dvd_spu_subpic_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
} else if (packet_size < size) {
/* Somehow we collected too much - something is wrong. Drop the
* packet entirely and wait for a new one */
GST_DEBUG_OBJECT (dvdspu, "Discarding invalid SPU buffer of size %u",
size);
GST_DEBUG_OBJECT (dvdspu,
"Discarding invalid SPU buffer of size %" G_GSIZE_FORMAT, size);
gst_buffer_unref (dvdspu->partial_spu);
dvdspu->partial_spu = NULL;
} else {
GST_LOG_OBJECT (dvdspu,
"SPU buffer claims to be of size %u. Collected %u so far.",
packet_size, size);
"SPU buffer claims to be of size %u. Collected %" G_GSIZE_FORMAT
" so far.", packet_size, size);
}
}
break;
@ -985,7 +986,8 @@ gst_dvd_spu_subpic_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
dvdspu->partial_spu = NULL;
} else if (ptr == end) {
GST_DEBUG_OBJECT (dvdspu,
"Have complete PGS packet of size %u. Enqueueing.", size);
"Have complete PGS packet of size %" G_GSIZE_FORMAT ". Enqueueing.",
size);
submit_new_spu_packet (dvdspu, dvdspu->partial_spu);
dvdspu->partial_spu = NULL;
}

View file

@ -1322,7 +1322,7 @@ mpegts_packetizer_parse_nit (MpegTSPacketizer2 * packetizer,
}
if (data != end - 4) {
GST_WARNING ("PID %d invalid NIT parsed %d length %d",
GST_WARNING ("PID %d invalid NIT parsed %d length %" G_GSIZE_FORMAT,
section->pid, (gint) (data - bufdata), size);
goto error;
}
@ -1533,7 +1533,7 @@ mpegts_packetizer_parse_sdt (MpegTSPacketizer2 * packetizer,
}
if (data != end - 4) {
GST_WARNING ("PID %d invalid SDT parsed %d length %d",
GST_WARNING ("PID %d invalid SDT parsed %d length %" G_GSIZE_FORMAT,
section->pid, (gint) (data - bufdata), size);
goto error;
}
@ -1997,7 +1997,7 @@ mpegts_packetizer_parse_eit (MpegTSPacketizer2 * packetizer,
}
if (data != end - 4) {
GST_WARNING ("PID %d invalid EIT parsed %d length %d",
GST_WARNING ("PID %d invalid EIT parsed %d length %" G_GSIZE_FORMAT,
section->pid, (gint) (data - bufdata), size);
goto error;
}
@ -2172,7 +2172,7 @@ mpegts_packetizer_push (MpegTSPacketizer2 * packetizer, GstBuffer * buffer)
packetizer->offset = GST_BUFFER_OFFSET (buffer);
}
GST_DEBUG ("Pushing %u byte from offset %" G_GUINT64_FORMAT,
GST_DEBUG ("Pushing %" G_GSIZE_FORMAT " byte from offset %" G_GUINT64_FORMAT,
gst_buffer_get_size (buffer), GST_BUFFER_OFFSET (buffer));
gst_adapter_push (packetizer->adapter, buffer);
}
@ -2421,8 +2421,9 @@ mpegts_packetizer_push_section (MpegTSPacketizer2 * packetizer,
if (stream->continuity_counter != CONTINUITY_UNSET) {
GST_DEBUG
("PID %d table_id %d sub_table_extension %d payload_unit_start_indicator set but section "
"not complete (last_continuity: %d continuity: %d sec len %d buffer %d avail %d",
packet->pid, table_id, subtable_extension, stream->continuity_counter,
"not complete (last_continuity: %d continuity: %d sec len %d buffer %"
G_GSIZE_FORMAT " avail %" G_GSIZE_FORMAT, packet->pid, table_id,
subtable_extension, stream->continuity_counter,
packet->continuity_counter, section_length,
gst_buffer_get_size (sub_buf), stream->section_adapter->size);
mpegts_packetizer_clear_section (packetizer, stream);

View file

@ -2052,8 +2052,9 @@ gst_ts_demux_queue_data (GstTSDemux * demux, TSDemuxStream * stream,
buf = packet->buffer;
data = gst_buffer_map (buf, &size, 0, GST_MAP_READ);
GST_DEBUG ("Resizing buffer to %d (size:%d) (Was %d bytes long)",
packet->payload - data, packet->data_end - packet->payload, size);
GST_DEBUG ("Resizing buffer to %d (size:%d) (Was %" G_GSIZE_FORMAT
" bytes long)", (int) (packet->payload - data),
(int) (packet->data_end - packet->payload), size);
gst_buffer_unmap (buf, data, size);
gst_buffer_resize (buf, packet->payload - data,
@ -2250,7 +2251,7 @@ gst_ts_demux_handle_packet (GstTSDemux * demux, TSDemuxStream * stream,
packet->continuity_counter, packet->payload);
if (section) {
GST_DEBUG ("section complete:%d, buffer size %d",
GST_DEBUG ("section complete:%d, buffer size %" G_GSIZE_FORMAT,
section->complete, gst_buffer_get_size (section->buffer));
gst_buffer_unref (packet->buffer);
return res;

View file

@ -523,7 +523,7 @@ gst_y4m_dec_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
len = strlen (header);
if (n_avail < y4mdec->info.size + len + 1) {
/* not enough data */
GST_DEBUG ("not enough data for frame %d < %d",
GST_DEBUG ("not enough data for frame %d < %" G_GSIZE_FORMAT,
n_avail, y4mdec->info.size + len + 1);
break;
}