Commit 2143a6e4 authored by Ognyan Tonchev's avatar Ognyan Tonchev Committed by Wim Taymans
Browse files

jpegpay: consider header len when calculating payload len

Fixed https://bugzilla.gnome.org/show_bug.cgi?id=726777
parent 94bfdc7a
......@@ -813,10 +813,16 @@ gst_rtp_jpeg_pay_handle_buffer (GstRTPBasePayload * basepayload,
do {
GstBuffer *outbuf;
guint8 *payload;
guint payload_size = (bytes_left < mtu ? bytes_left : mtu);
guint payload_size;
guint header_size;
GstBuffer *paybuf;
GstRTPBuffer rtp = { NULL };
guint rtp_header_size = gst_rtp_buffer_calc_header_len (0);
/* The available room is the packet MTU, minus the RTP header length. */
payload_size =
(bytes_left < (mtu - rtp_header_size) ? bytes_left :
(mtu - rtp_header_size));
header_size = sizeof (jpeg_header) + quant_data_size;
if (dri_found)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment