[Bug 748344] New: bufferpool: in renegotation, bufferpool can be given to element while another one still uses it

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Apr 22 17:09:08 PDT 2015


https://bugzilla.gnome.org/show_bug.cgi?id=748344

            Bug ID: 748344
           Summary: bufferpool: in renegotation, bufferpool can be given
                    to element while another one still uses it
    Classification: Platform
           Product: GStreamer
           Version: git master
                OS: All
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: gstreamer (core)
          Assignee: gstreamer-bugs at lists.freedesktop.org
          Reporter: thiagossantos at gmail.com
        QA Contact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---

Suppose the following pipeline:

source ! filter ! sink

Initially it works in passthrough mode so source gets a bufferpool from sink
and uses it.

At some point when filter gets a buffer it decides it can't do passthrough
anymore (the user might have set a property to it, for example).

Filter will request a bufferpool from sink. If the caps in the request are the
same as source have been using the sink might return the same bufferpool. It
sets the bufferpool to active (it already was active) and will use it to push a
buffer. In this process filter also sent a reconfigure upstream to make source
realize it isn't in passthrough anymore and that it should request a new
bufferpool.

At the next source loop it will do the reconfigure and as part of the
acquisition of a new bufferpool, set the old one to inactive.

Now filter receives the new buffer from source and tries to get a buffer from
the pool to use. This same pool has been stopped by source in its renegotiation
and filter will fail because its pool is now unexpectedly flushing.

Adding queues to the pipeline can make this racy as well.

I have an unfinished work that triggers this issue and I'll try to make it into
an application so others can easily reproduce it. (Likely uploading it
tomorrow)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list