]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - glsdk/gst-plugin-ducati.git/commitdiff
ducatividdec: don't renegotiate while flushing
authorAlessandro Decina <alessandro.decina@collabora.co.uk>
Tue, 29 Nov 2011 19:54:47 +0000 (20:54 +0100)
committerAlessandro Decina <alessandro.decina@collabora.co.uk>
Tue, 29 Nov 2011 19:54:47 +0000 (20:54 +0100)
Fixes a crash introduced by calling codec_flush in PAUSED=>READY

src/gstducatividdec.c

index d7c00dbf0976655419e5ba38b31d58c26c8c98bd..97a9aa14e67078868e603f20993650360732ef0d 100644 (file)
@@ -324,7 +324,10 @@ codec_process (GstDucatiVidDec * self, gboolean send, gboolean flush)
 
     interlaced = self->outArgs->decodedBufs.contentType == IVIDEO_PROGRESSIVE ? FALSE : TRUE;
 
-    if (interlaced != self->interlaced) {
+    /* if send is FALSE, don't try to renegotiate as we could be flushing during
+     * a PAUSED->READY state change
+     */
+    if (send && interlaced != self->interlaced) {
       GstCaps *caps;
 
       GST_WARNING_OBJECT (self, "upstream set interlaced=%d but codec "