tsdemux: reset the state of the stream when flushing
authorWim Taymans <wim.taymans@collabora.co.uk>
Mon, 30 Apr 2012 10:28:42 +0000 (12:28 +0200)
committerWim Taymans <wim.taymans@collabora.co.uk>
Tue, 1 May 2012 09:47:52 +0000 (11:47 +0200)
We need to reset the stream on a flush or else old packets could be added to the
list and leak.

gst/mpegtsdemux/tsdemux.c

index f7be0d9257c5c932b4e3a24c340b219cfd912599..a4336dcdc2152cbf910760cf619b30c030e92f53 100644 (file)
@@ -1023,6 +1023,7 @@ gst_ts_demux_stream_flush (TSDemuxStream * stream)
     stream->currentlist = NULL;
   }
 
+  stream->state = PENDING_PACKET_EMPTY;
   stream->expected_size = 0;
   stream->current_size = 0;
   stream->need_newsegment = TRUE;