Eliminate a copy and allocation for each incoming video packet

This commit is contained in:
Cameron Gutman committed 2019-04-25 22:07:03 -07:00
1 parent c87d4a755e
commit f395d3056a
4 files changed
+107 -42

No files matched your search

+1 -1
View File
@@ -126,8 +126,8 @@ static void ReceiveThreadProc(void* context) {
// The packet queue now has packets ready
buffer = NULL;
while ((queueEntry = RtpfGetQueuedPacket(&rtpQueue)) != NULL) {
// queueRtpPacket takes ownership of the packet
queueRtpPacket(queueEntry);
free(queueEntry->packet);
}
}
else if (queueStatus == RTPF_RET_QUEUED_NOTHING_READY) {