From: Vincent Penquerc'h Date: Wed, 14 Sep 2011 11:23:19 +0000 (+0100) Subject: oggdemux: fix wedge when seeking twice quickly in push mode X-Git-Tag: 1.19.3~511^2~6555^2~484 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=89fc5b4bd8714d4d666d5cee8139495712389e20;p=platform%2Fupstream%2Fgstreamer.git oggdemux: fix wedge when seeking twice quickly in push mode This could happen when testing with navseek, and pressing right and left at roughly the same time. The current chain is temporarily moved away, and this caused the flush events not to be sent to the source pads, which would cause the data queues downstream to reject incoming data after the seek, and shut down, wedging the pipeline. Now, I can't really decide whether this is a nasty steaming hack or a good fix, but it certainly does fix the issue, and does not seem to break anything else so far. https://bugzilla.gnome.org/show_bug.cgi?id=621897 --- diff --git a/ext/ogg/gstoggdemux.c b/ext/ogg/gstoggdemux.c index 16f559e..ade8645 100644 --- a/ext/ogg/gstoggdemux.c +++ b/ext/ogg/gstoggdemux.c @@ -3982,6 +3982,9 @@ gst_ogg_demux_send_event (GstOggDemux * ogg, GstEvent * event) GstOggChain *chain = ogg->current_chain; gboolean res = TRUE; + if (!chain) + chain = ogg->building_chain; + if (chain) { gint i; @@ -3992,6 +3995,8 @@ gst_ogg_demux_send_event (GstOggDemux * ogg, GstEvent * event) GST_DEBUG_OBJECT (pad, "Pushing event %" GST_PTR_FORMAT, event); res &= gst_pad_push_event (GST_PAD (pad), event); } + } else { + GST_WARNING_OBJECT (ogg, "No chain to forward event to"); } gst_event_unref (event);