Commit 42fa4cb2 authored by Olivier Crête's avatar Olivier Crête 👻

srtsrc: Receive one frame per gstbuffer

Don't aggregate the received data, just receive it one packet at a
time. So it keeps the packetization boundaries
parent 1acd9c72
......@@ -1191,25 +1191,11 @@ gst_srt_object_read (GstSRTObject * srtobject,
continue;
}
while (len < size) {
gint recv;
gint rest = size - len;
/* Workaround for SRT being unhappy about buffers that
* are less than the chunk size */
if (rest < msg_size)
goto out;
recv = srt_recvmsg (rsock, (char *) (data + len), rest);
if (recv <= 0)
goto out;
len += recv;
}
len = srt_recvmsg (rsock, (char *) (data), size);
break;
}
out:
return len;
}
......
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