From: Edward Hervey Date: Wed, 29 Sep 2010 16:54:28 +0000 (+0200) Subject: decodebin2: Don't post async-done when not needed X-Git-Tag: RELEASE-0.10.31~149 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b8dea19bbdb0571e31fbcf3c65516dbe4a92bf76;p=platform%2Fupstream%2Fgst-plugins-base.git decodebin2: Don't post async-done when not needed Where it was previously located, we would get async-done for the first unknown-type, even if other valid streams would appear afterwards. decode_bin_expose() will take care of posting async-done when the group is exposed. But we still want to post it in case the typefinding returned an unknown type, in which case we will post it after posting an error. These two changes ensure we do as much as possible before posting async-done. --- diff --git a/gst/playback/gstdecodebin2.c b/gst/playback/gstdecodebin2.c index 4553294..7877c21 100644 --- a/gst/playback/gstdecodebin2.c +++ b/gst/playback/gstdecodebin2.c @@ -1522,7 +1522,6 @@ unknown_type: gst_decode_bin_expose (dbin); } EXPOSE_UNLOCK (dbin); - do_async_done (dbin); if (src == dbin->typefind) { gchar *desc; @@ -1540,6 +1539,7 @@ unknown_type: (_("Could not determine type of stream")), ("Stream caps %" GST_PTR_FORMAT, caps)); } + do_async_done (dbin); } return; }