mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-11 09:55:36 +00:00
Fix print format compiler warnings on OS X / 64bit
https://bugzilla.gnome.org/show_bug.cgi?id=662617
This commit is contained in:
parent
03bc286c64
commit
4b57b9288b
7 changed files with 41 additions and 35 deletions
|
@ -960,7 +960,7 @@ gst_asf_demux_pull_data (GstASFDemux * demux, guint64 offset, guint size,
|
|||
buffer_size = gst_buffer_get_size (*p_buf);
|
||||
if (G_UNLIKELY (buffer_size < size)) {
|
||||
GST_DEBUG_OBJECT (demux, "short read pulling buffer at %" G_GUINT64_FORMAT
|
||||
"+%u (got only %u bytes)", offset, size, buffer_size);
|
||||
"+%u (got only %" G_GSIZE_FORMAT " bytes)", offset, size, buffer_size);
|
||||
gst_buffer_unref (*p_buf);
|
||||
if (G_LIKELY (p_flow))
|
||||
*p_flow = GST_FLOW_UNEXPECTED;
|
||||
|
@ -1477,7 +1477,7 @@ gst_asf_demux_push_complete_payloads (GstASFDemux * demux, gboolean force)
|
|||
/* FIXME: we should really set durations on buffers if we can */
|
||||
|
||||
GST_LOG_OBJECT (stream->pad, "pushing buffer, ts=%" GST_TIME_FORMAT
|
||||
", dur=%" GST_TIME_FORMAT " size=%u",
|
||||
", dur=%" GST_TIME_FORMAT " size=%" G_GSIZE_FORMAT,
|
||||
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (payload->buf)),
|
||||
GST_TIME_ARGS (GST_BUFFER_DURATION (payload->buf)),
|
||||
gst_buffer_get_size (payload->buf));
|
||||
|
@ -1769,7 +1769,8 @@ gst_asf_demux_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
|
||||
demux = GST_ASF_DEMUX (parent);
|
||||
|
||||
GST_LOG_OBJECT (demux, "buffer: size=%u, offset=%" G_GINT64_FORMAT ", time=%"
|
||||
GST_LOG_OBJECT (demux,
|
||||
"buffer: size=%" G_GSIZE_FORMAT ", offset=%" G_GINT64_FORMAT ", time=%"
|
||||
GST_TIME_FORMAT, gst_buffer_get_size (buf), GST_BUFFER_OFFSET (buf),
|
||||
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)));
|
||||
|
||||
|
@ -2348,7 +2349,7 @@ gst_asf_demux_parse_stream_object (GstASFDemux * demux, guint8 * data,
|
|||
|
||||
flags = gst_asf_demux_get_uint16 (&data, &size);
|
||||
stream_id = flags & 0x7f;
|
||||
is_encrypted = ! !((flags & 0x8000) << 15);
|
||||
is_encrypted = !!((flags & 0x8000) << 15);
|
||||
unknown = gst_asf_demux_get_uint32 (&data, &size);
|
||||
|
||||
GST_DEBUG_OBJECT (demux, "Found stream %u, time_offset=%" GST_TIME_FORMAT,
|
||||
|
@ -2956,8 +2957,8 @@ gst_asf_demux_process_file (GstASFDemux * demux, guint8 * data, guint64 size)
|
|||
max_pktsize = gst_asf_demux_get_uint32 (&data, &size);
|
||||
min_bitrate = gst_asf_demux_get_uint32 (&data, &size);
|
||||
|
||||
demux->broadcast = ! !(flags & 0x01);
|
||||
demux->seekable = ! !(flags & 0x02);
|
||||
demux->broadcast = !!(flags & 0x01);
|
||||
demux->seekable = !!(flags & 0x02);
|
||||
|
||||
GST_DEBUG_OBJECT (demux, "min_pktsize = %u", min_pktsize);
|
||||
GST_DEBUG_OBJECT (demux, "flags::broadcast = %d", demux->broadcast);
|
||||
|
@ -3783,10 +3784,10 @@ gst_asf_demux_descramble_buffer (GstASFDemux * demux, AsfStream * stream,
|
|||
idx = row + col * demux->ds_packet_size / demux->ds_chunk_size;
|
||||
GST_DEBUG ("idx=%u, row=%u, col=%u, off=%u, ds_chunk_size=%u", idx, row,
|
||||
col, off, demux->ds_chunk_size);
|
||||
GST_DEBUG ("scrambled buffer size=%u, span=%u, packet_size=%u",
|
||||
gst_buffer_get_size (scrambled_buffer), demux->span,
|
||||
demux->ds_packet_size);
|
||||
GST_DEBUG ("gst_buffer_get_size (scrambled_buffer) = %u",
|
||||
GST_DEBUG ("scrambled buffer size=%" G_GSIZE_FORMAT
|
||||
", span=%u, packet_size=%u", gst_buffer_get_size (scrambled_buffer),
|
||||
demux->span, demux->ds_packet_size);
|
||||
GST_DEBUG ("gst_buffer_get_size (scrambled_buffer) = %" G_GSIZE_FORMAT,
|
||||
gst_buffer_get_size (scrambled_buffer));
|
||||
sub_buffer =
|
||||
gst_buffer_copy_region (scrambled_buffer, GST_BUFFER_COPY_NONE,
|
||||
|
|
|
@ -464,8 +464,9 @@ gst_rtp_asf_depay_process (GstRTPBaseDepayload * depayload, GstBuffer * buf)
|
|||
if (plen < depay->packet_size) {
|
||||
GstBuffer *tmp;
|
||||
|
||||
GST_LOG_OBJECT (depay, "padding buffer size %d to packet size %d",
|
||||
plen, depay->packet_size);
|
||||
GST_LOG_OBJECT (depay,
|
||||
"padding buffer size %" G_GSIZE_FORMAT " to packet size %d", plen,
|
||||
depay->packet_size);
|
||||
|
||||
tmp = gst_buffer_new_and_alloc (depay->packet_size);
|
||||
gst_buffer_copy_into (tmp, outbuf, GST_BUFFER_COPY_ALL, 0, plen);
|
||||
|
|
|
@ -460,8 +460,8 @@ gst_dvdlpcmdec_chain_dvd (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
dvdlpcmdec->header = header;
|
||||
}
|
||||
|
||||
GST_LOG_OBJECT (dvdlpcmdec, "first_access %d, buffer length %d", first_access,
|
||||
size);
|
||||
GST_LOG_OBJECT (dvdlpcmdec, "first_access %d, buffer length %" G_GSIZE_FORMAT,
|
||||
first_access, size);
|
||||
|
||||
rate = GST_AUDIO_INFO_RATE (&dvdlpcmdec->info);
|
||||
channels = GST_AUDIO_INFO_CHANNELS (&dvdlpcmdec->info);
|
||||
|
@ -537,8 +537,9 @@ gst_dvdlpcmdec_chain_dvd (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
ret = gst_dvdlpcmdec_chain_raw (pad, parent, subbuf);
|
||||
}
|
||||
} else {
|
||||
GST_LOG_OBJECT (dvdlpcmdec, "Creating single sub-buffer off %d, len %d",
|
||||
off, size - off);
|
||||
GST_LOG_OBJECT (dvdlpcmdec,
|
||||
"Creating single sub-buffer off %d, len %" G_GSIZE_FORMAT, off,
|
||||
size - off);
|
||||
subbuf = gst_buffer_copy_region (buf, GST_BUFFER_COPY_ALL, off, size - off);
|
||||
GST_BUFFER_TIMESTAMP (subbuf) = GST_BUFFER_TIMESTAMP (buf);
|
||||
ret = gst_dvdlpcmdec_chain_raw (pad, parent, subbuf);
|
||||
|
@ -600,7 +601,7 @@ gst_dvdlpcmdec_chain_raw (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
size = gst_buffer_get_size (buf);
|
||||
|
||||
GST_LOG_OBJECT (dvdlpcmdec,
|
||||
"got buffer %p of size %d with ts %" GST_TIME_FORMAT,
|
||||
"got buffer %p of size %" G_GSIZE_FORMAT " with ts %" GST_TIME_FORMAT,
|
||||
buf, size, GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)));
|
||||
|
||||
rate = GST_AUDIO_INFO_RATE (&dvdlpcmdec->info);
|
||||
|
@ -723,8 +724,8 @@ done:
|
|||
/* ERRORS */
|
||||
drop:
|
||||
{
|
||||
GST_DEBUG_OBJECT (dvdlpcmdec, "Buffer of size %u is too small. Dropping",
|
||||
size);
|
||||
GST_DEBUG_OBJECT (dvdlpcmdec,
|
||||
"Buffer of size %" G_GSIZE_FORMAT " is too small. Dropping", size);
|
||||
gst_buffer_unref (buf);
|
||||
ret = GST_FLOW_OK;
|
||||
goto done;
|
||||
|
|
|
@ -807,7 +807,7 @@ gst_dvd_sub_dec_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
|
||||
dec = GST_DVD_SUB_DEC (parent);
|
||||
|
||||
GST_DEBUG_OBJECT (dec, "Have buffer of size %d, ts %"
|
||||
GST_DEBUG_OBJECT (dec, "Have buffer of size %" G_GSIZE_FORMAT ", ts %"
|
||||
GST_TIME_FORMAT ", dur %" G_GINT64_FORMAT, gst_buffer_get_size (buf),
|
||||
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)), GST_BUFFER_DURATION (buf));
|
||||
|
||||
|
|
|
@ -154,7 +154,7 @@ gst_dvd_sub_parse_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
|
||||
adapter = parse->adapter;
|
||||
|
||||
GST_LOG_OBJECT (parse, "%4u bytes, ts: %" GST_TIME_FORMAT,
|
||||
GST_LOG_OBJECT (parse, "%" G_GSIZE_FORMAT " bytes, ts: %" GST_TIME_FORMAT,
|
||||
gst_buffer_get_size (buf), GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)));
|
||||
|
||||
gst_adapter_push (adapter, buf);
|
||||
|
|
|
@ -672,7 +672,8 @@ pull_range_error:
|
|||
pull_range_short_read:
|
||||
{
|
||||
GST_WARNING_OBJECT (demux, "pull range short read: wanted %u bytes, but "
|
||||
"got only %u bytes", bytes_needed, gst_buffer_get_size (buf));
|
||||
"got only %" G_GSIZE_FORMAT " bytes", bytes_needed,
|
||||
gst_buffer_get_size (buf));
|
||||
gst_buffer_unref (buf);
|
||||
goto eos;
|
||||
}
|
||||
|
|
|
@ -963,7 +963,7 @@ gst_rmdemux_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
|
|||
|
||||
gst_adapter_push (rmdemux->adapter, buffer);
|
||||
|
||||
GST_LOG_OBJECT (rmdemux, "Chaining buffer of size %d",
|
||||
GST_LOG_OBJECT (rmdemux, "Chaining buffer of size %" G_GSIZE_FORMAT,
|
||||
gst_buffer_get_size (buffer));
|
||||
|
||||
while (TRUE) {
|
||||
|
@ -1108,7 +1108,7 @@ gst_rmdemux_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
|
|||
|
||||
/* The actual header is only 8 bytes */
|
||||
rmdemux->size = DATA_SIZE;
|
||||
GST_LOG_OBJECT (rmdemux, "data available %d",
|
||||
GST_LOG_OBJECT (rmdemux, "data available %" G_GSIZE_FORMAT,
|
||||
gst_adapter_available (rmdemux->adapter));
|
||||
if (gst_adapter_available (rmdemux->adapter) < rmdemux->size)
|
||||
goto unlock;
|
||||
|
@ -2091,8 +2091,9 @@ gst_rmdemux_handle_scrambled_packet (GstRMDemux * rmdemux,
|
|||
if (stream->subpackets == NULL)
|
||||
stream->subpackets = g_ptr_array_sized_new (stream->subpackets_needed);
|
||||
|
||||
GST_LOG ("Got subpacket %u/%u, len=%u, key=%d", stream->subpackets->len + 1,
|
||||
stream->subpackets_needed, gst_buffer_get_size (buf), keyframe);
|
||||
GST_LOG ("Got subpacket %u/%u, len=%" G_GSIZE_FORMAT ", key=%d",
|
||||
stream->subpackets->len + 1, stream->subpackets_needed,
|
||||
gst_buffer_get_size (buf), keyframe);
|
||||
|
||||
if (keyframe && stream->subpackets->len > 0) {
|
||||
gst_rmdemux_stream_clear_cached_subpackets (rmdemux, stream);
|
||||
|
@ -2338,8 +2339,9 @@ gst_rmdemux_parse_video_packet (GstRMDemux * rmdemux, GstRMDemuxStream * stream,
|
|||
}
|
||||
|
||||
GST_DEBUG_OBJECT (rmdemux,
|
||||
"seq %d, subseq %d, offset %d, length %d, size %d, header %02x",
|
||||
pkg_seqnum, pkg_subseq, pkg_offset, pkg_length, size, pkg_header);
|
||||
"seq %d, subseq %d, offset %d, length %d, size %" G_GSIZE_FORMAT
|
||||
", header %02x", pkg_seqnum, pkg_subseq, pkg_offset, pkg_length, size,
|
||||
pkg_header);
|
||||
|
||||
/* calc size of fragment */
|
||||
if ((pkg_header & 0xc0) == 0x80) {
|
||||
|
@ -2466,7 +2468,7 @@ gst_rmdemux_parse_video_packet (GstRMDemux * rmdemux, GstRMDemuxStream * stream,
|
|||
data += fragment_size;
|
||||
size -= fragment_size;
|
||||
}
|
||||
GST_DEBUG_OBJECT (rmdemux, "%d bytes left", size);
|
||||
GST_DEBUG_OBJECT (rmdemux, "%" G_GSIZE_FORMAT " bytes left", size);
|
||||
|
||||
done:
|
||||
gst_buffer_unmap (in, base, -1);
|
||||
|
@ -2518,9 +2520,9 @@ gst_rmdemux_parse_audio_packet (GstRMDemux * rmdemux, GstRMDemuxStream * stream,
|
|||
ret = gst_rmdemux_handle_scrambled_packet (rmdemux, stream, buffer, key);
|
||||
} else {
|
||||
GST_LOG_OBJECT (rmdemux,
|
||||
"Pushing buffer of size %d, timestamp %" GST_TIME_FORMAT "to pad %s",
|
||||
gst_buffer_get_size (buffer), GST_TIME_ARGS (timestamp),
|
||||
GST_PAD_NAME (stream->pad));
|
||||
"Pushing buffer of size %" G_GSIZE_FORMAT ", timestamp %"
|
||||
GST_TIME_FORMAT "to pad %s", gst_buffer_get_size (buffer),
|
||||
GST_TIME_ARGS (timestamp), GST_PAD_NAME (stream->pad));
|
||||
|
||||
if (stream->discont) {
|
||||
GST_BUFFER_FLAG_SET (buffer, GST_BUFFER_FLAG_DISCONT);
|
||||
|
@ -2563,7 +2565,7 @@ gst_rmdemux_parse_packet (GstRMDemux * rmdemux, GstBuffer * in, guint16 version)
|
|||
rmdemux->segment.position = timestamp;
|
||||
|
||||
GST_LOG_OBJECT (rmdemux, "Parsing a packet for stream=%d, timestamp=%"
|
||||
GST_TIME_FORMAT ", size %u, version=%d, ts=%u", id,
|
||||
GST_TIME_FORMAT ", size %" G_GSIZE_FORMAT ", version=%d, ts=%u", id,
|
||||
GST_TIME_ARGS (timestamp), size, version, ts);
|
||||
|
||||
if (rmdemux->first_ts == GST_CLOCK_TIME_NONE) {
|
||||
|
@ -2619,8 +2621,8 @@ gst_rmdemux_parse_packet (GstRMDemux * rmdemux, GstBuffer * in, guint16 version)
|
|||
|
||||
if ((rmdemux->offset + size) <= stream->seek_offset) {
|
||||
GST_DEBUG_OBJECT (rmdemux,
|
||||
"Stream %d is skipping: seek_offset=%d, offset=%d, size=%u",
|
||||
stream->id, stream->seek_offset, rmdemux->offset, size);
|
||||
"Stream %d is skipping: seek_offset=%d, offset=%d, size=%"
|
||||
G_GSIZE_FORMAT, stream->id, stream->seek_offset, rmdemux->offset, size);
|
||||
cret = GST_FLOW_OK;
|
||||
gst_buffer_unref (in);
|
||||
goto beach;
|
||||
|
|
Loading…
Reference in a new issue