GNOME Bugzilla – Bug 337386
Pipeline bus is not initially flushing
Last modified: 2006-04-05 15:48:00 UTC
When a pipeline bus is created, it isn't initially flushing. However, if we change the pipeline from NULL to READY then back to NULL, it will (by default) be flushing. I'm fairly sure we should be setting this bus to flushing on creation (we already set it to non-flushing when we go to READY). This causes leaks in tests/check/gst/gstghostpad.c (revealed when running under valgrind), as we add things to a pipeline when in NULL, receive a clock-provide message, and this message is never flushed (or read). The clock-provides message is itself bogus in this test (I'll file another bug for that), but if the added element was a real clock provider, this would be triggerable anyway. I'll attach a patch that implements the behaviour I suggested, but I'm not sure how correct it is. Feedback appreciated. Note that this will cause any application listening for clock-provide messages on the bus with a pipeline in NULL to break. However, this is a pretty obscure case, and I don't know of any application that listens for clock-provide messages in any state.
Created attachment 62805 [details] [review] Set pipeline bus to flushing on creation Implement behaviour as described.
Patch committed with wim's approval.