[PATCH 1/7] gstomxvideodec: fix multithreads negotiation problem

Christian König deathsimple at vodafone.de
Thu Feb 6 09:39:35 PST 2014


From: Leo Liu <leo.liu at amd.com>

Signed-off-by: Leo Liu <leo.liu at amd.com>
---
 omx/gstomxvideodec.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/omx/gstomxvideodec.c b/omx/gstomxvideodec.c
index bf44b3d..32cb4a2 100644
--- a/omx/gstomxvideodec.c
+++ b/omx/gstomxvideodec.c
@@ -2676,6 +2676,11 @@ gst_omx_video_dec_set_format (GstVideoDecoder * decoder,
       GST_LOG_OBJECT (self, "Negotiation failed, will get output format later");
 
     /* Disable output port */
+    /* make sure multithread safe */
+    if (gst_omx_port_wait_enabled (self->dec_out_port,
+            1 * GST_SECOND) != OMX_ErrorNone)
+      return FALSE;
+
     if (gst_omx_port_set_enabled (self->dec_out_port, FALSE) != OMX_ErrorNone)
       return FALSE;
 
-- 
1.8.3.2



More information about the gstreamer-openmax mailing list