From 49f24e2044bcc8afc78b99e7f6b7fa0aef3864e5 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 5 Aug 2009 13:47:33 +0200 Subject: [PATCH] queue: get caps after making writable Get the caps of the buffer after we made the buffer writable. This did not cause any problems but it's nicer this way. --- plugins/elements/gstqueue.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/elements/gstqueue.c b/plugins/elements/gstqueue.c index 175fc6b..20380af 100644 --- a/plugins/elements/gstqueue.c +++ b/plugins/elements/gstqueue.c @@ -1021,7 +1021,6 @@ next: GstCaps *caps; buffer = GST_BUFFER_CAST (data); - caps = GST_BUFFER_CAPS (buffer); if (queue->head_needs_discont) { GstBuffer *subbuffer = gst_buffer_make_metadata_writable (buffer); @@ -1035,6 +1034,8 @@ next: queue->head_needs_discont = FALSE; } + caps = GST_BUFFER_CAPS (buffer); + GST_QUEUE_MUTEX_UNLOCK (queue); /* set the right caps on the pad now. We do this before pushing the buffer * because the pad_push call will check (using acceptcaps) if the buffer can -- 2.7.4