[Bug 791193] New: GstElement::request_new_pad() is racy

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Dec 4 09:03:49 UTC 2017


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

            Bug ID: 791193
           Summary: GstElement::request_new_pad() is racy
    Classification: Platform
           Product: GStreamer
           Version: unspecified
                OS: Linux
            Status: NEW
          Severity: major
          Priority: Normal
         Component: gstreamer (core)
          Assignee: gstreamer-bugs at lists.freedesktop.org
          Reporter: slomo at coaxion.net
        QA Contact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---

Currently the subclass is expected to return an unowned (transfer none) pad
reference, which is assumed to be owned by the element. The caller
(gst_element_get_request_pad() / gst_element_request_pad()) is directly calling
gst_object_ref().

But there's a small window in which the pad could be removed from the element
again before the gst_object_ref(), causing an invalid pointer to freed memory
to be returned to the caller.


I don't see how we can fix this in 1.0 without adding a new vfunc that has the
return value as (transfer full).

-- 
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