summaryrefslogtreecommitdiff
path: root/toxav
diff options
context:
space:
mode:
Diffstat (limited to 'toxav')
-rw-r--r--toxav/codec.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/toxav/codec.c b/toxav/codec.c
index 448edd4c..1e8478bb 100644
--- a/toxav/codec.c
+++ b/toxav/codec.c
@@ -61,8 +61,10 @@ JitterBuffer *create_queue(unsigned int capacity)
61static void clear_queue(JitterBuffer *q) 61static void clear_queue(JitterBuffer *q)
62{ 62{
63 for (; q->bottom != q->top; ++q->bottom) { 63 for (; q->bottom != q->top; ++q->bottom) {
64 if (q->queue[q->bottom % q->size]) 64 if (q->queue[q->bottom % q->size]) {
65 rtp_free_msg(NULL, q->queue[q->bottom % q->size]); 65 rtp_free_msg(NULL, q->queue[q->bottom % q->size]);
66 q->queue[q->bottom % q->size] = NULL;
67 }
66 } 68 }
67} 69}
68 70