GNOME Bugzilla – Bug 710881
memory leaks in hlsdemux
Last modified: 2013-10-26 02:26:56 UTC
During normal operation hlsdemux is leaking memory. On the embedded device that I am developing for, this causes gstreamer to die after about 15 minutes of 1.5mbps video. Checking with valgrind on a Linux desktop I can see a "possibly lost" of several MB of memory that it is allocated in hlsdemux. The problem is that gst_hls_demux_get_next_fragment function calls gst_fragment_get_buffer which increments the reference count on the buffer but gst_hls_demux_get_next_fragment never calls unref on the buffer. This means that the reference count for each downloaded fragment never gets to zero and so its memory is never released. I will attach a patch (against 1.2.0) that fixes this, plus two other very minor leaks that I've found. I have also checked git head and the bug is present there as well.
Created attachment 258130 [details] [review] fixes three memory leaks in hlsdemux This patch fixes three memory leaks in hlsdemux, one that occurs during normal operation and two that occur during error conditions.
Fixed by this commit commit 58072914fabf872b46b4787c190401acbed24c64 Author: Alex Ashley <bugzilla@ashley-family.net> Date: Fri Oct 25 11:11:30 2013 +0100