tsmux: Store PES payload size in a 32 bit integer

While the size in the packet is only 16 bits, we need to handle bigger
sizes without overflowing. For video streams this can happen, 0 is
written to the stream instead.

This fixes muxing of buffers >= 2**16.
This commit is contained in:
Sebastian Dröge 2017-07-21 09:27:20 +03:00
parent bbbdc2cd7e
commit 3fe65ad854

View file

@ -184,9 +184,9 @@ struct TsMuxStream {
/* optional fixed PES size for stream type */
guint16 pes_payload_size;
/* current PES payload size being written */
guint16 cur_pes_payload_size;
guint32 cur_pes_payload_size;
/* ... of which already this much written */
guint16 pes_bytes_written;
guint32 pes_bytes_written;
/* PTS/DTS to write if the flags in the packet info are set */
/* in MPEG PTS clock time */