summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorAndoni Morales Alastruey <ylatuya@gmail.com>2013-04-04 15:59:09 +0000
committerSebastian Dröge <sebastian.droege@collabora.co.uk>2013-04-15 09:02:37 +0200
commit27c546ad1ee5398127806749640466344819c8c5 (patch)
tree6fb5f5252365c011579eb3bf75732ecc5b660e24 /sys
parentd7c6d240b551bae8d674c46587e3b5027d1cc295 (diff)
downloadgstreamer-plugins-bad-27c546ad1ee5398127806749640466344819c8c5.tar.gz
avfvideosrc: fix deadlock draining queue from the same thread
Diffstat (limited to 'sys')
-rw-r--r--sys/applemedia/avfvideosrc.m3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/applemedia/avfvideosrc.m b/sys/applemedia/avfvideosrc.m
index 236aa7550..3c570b1a6 100644
--- a/sys/applemedia/avfvideosrc.m
+++ b/sys/applemedia/avfvideosrc.m
@@ -601,7 +601,8 @@ didOutputSampleBuffer:(CMSampleBufferRef)sampleBuffer
- (void)waitForQueueToDrain:(dispatch_queue_t)dispatchQueue
{
- dispatch_sync (dispatchQueue, ^{});
+ if (dispatchQueue != dispatch_get_current_queue())
+ dispatch_sync (dispatchQueue, ^{});
}
@end