valve: Only set discont on the first buffer after drops
authorOlivier Crête <olivier.crete@collabora.co.uk>
Fri, 28 Jan 2011 20:36:33 +0000 (15:36 -0500)
committerOlivier Crête <olivier.crete@collabora.co.uk>
Fri, 28 Jan 2011 20:38:17 +0000 (15:38 -0500)
Reset the discont member after setting discont on the first buffer after
dropping.

plugins/elements/gstvalve.c

index fdc175f..ae905f4 100644 (file)
@@ -184,6 +184,7 @@ gst_valve_chain (GstPad * pad, GstBuffer * buffer)
     if (valve->discont) {
       buffer = gst_buffer_make_metadata_writable (buffer);
       GST_BUFFER_FLAG_SET (buffer, GST_BUFFER_FLAG_DISCONT);
+      valve->discont = FALSE;
     }
 
     ret = gst_pad_push (valve->srcpad, buffer);