mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
rtph264depay: Exclude NALu size from payload length on truncated packets.
https://bugzilla.gnome.org/show_bug.cgi?id=667846
This commit is contained in:
parent
70565f0e75
commit
c16fed2ad9
1 changed files with 3 additions and 2 deletions
|
@ -735,8 +735,9 @@ gst_rtp_h264_depay_process (GstBaseRTPDepayload * depayload, GstBuffer * buf)
|
|||
*/
|
||||
nalu_size = (payload[0] << 8) | payload[1];
|
||||
|
||||
if (nalu_size > payload_len)
|
||||
nalu_size = payload_len;
|
||||
/* dont include nalu_size */
|
||||
if (nalu_size > (payload_len - 2))
|
||||
nalu_size = payload_len - 2;
|
||||
|
||||
outsize = nalu_size + sizeof (sync_bytes);
|
||||
outbuf = gst_buffer_new_and_alloc (outsize);
|
||||
|
|
Loading…
Reference in a new issue