[Bug 785957] New: GstAdaptiveDemuxStream leaks pad probes, causing gradual increase in CPU

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Aug 7 17:48:19 UTC 2017


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

            Bug ID: 785957
           Summary: GstAdaptiveDemuxStream leaks pad probes, causing
                    gradual increase in CPU
    Classification: Platform
           Product: GStreamer
           Version: git master
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: gst-plugins-bad
          Assignee: gstreamer-bugs at lists.freedesktop.org
          Reporter: gstreamer at btinternet.com
        QA Contact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---

Created attachment 357134
  --> https://bugzilla.gnome.org/attachment.cgi?id=357134&action=edit
Patch for IDLE probe leak

While testing our application it was observed that CPU utilization slowly
increased over time, which on low spec (i.e. embedded) hardware caused playback
to halt after several hours. This was tracked down to code in adaptivedemux
which added an IDLE probe to the elements source pad every time it downloaded a
fragment. These probes were never removed meaning an ever-increasing number of
probe callbacks had to be dispatched.

The attached patch fixes this resource leak by removing the IDLE probe when it
is no longer needed. It would probably be more optimal to use the same probe
throughout the lifetime of the element but the current logic relies on the fact
that the pad calls the probe callback when it is added if the pad is currently
idle, and it is not possible to determine this from outside the pad

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