After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 753188 - dashdemux: memory leak in gst_dash_demux_stream_update_fragment_info
dashdemux: memory leak in gst_dash_demux_stream_update_fragment_info
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal normal
: 1.5.90
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-08-03 15:55 UTC by Florin Apostol
Modified: 2015-08-16 13:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed patch (927 bytes, patch)
2015-08-03 16:01 UTC, Florin Apostol
committed Details | Review

Description Florin Apostol 2015-08-03 15:55:58 UTC
The gst_dash_demux_stream_update_fragment_info function could call gst_dash_demux_stream_update_headers_info function twice. The gst_dash_demux_stream_update_headers_info function will set header_uri and index_uri to some newly allocated strings. The values set by the first call of gst_dash_demux_stream_update_headers_info will leak when the function is called for a second time.

The solution is to call gst_adaptive_demux_stream_fragment_clear before the second call of gst_dash_demux_stream_update_headers_info
Comment 1 Florin Apostol 2015-08-03 16:01:20 UTC
Created attachment 308685 [details] [review]
proposed patch
Comment 2 Sebastian Dröge (slomo) 2015-08-05 22:24:49 UTC
commit 93c10d3f0ecd28a7164aea705ae6f623fca5030e
Author: Florin Apostol <florin.apostol@oregan.net>
Date:   Mon Aug 3 16:57:31 2015 +0100

    dashdemux: Fix leak in gst_dash_demux_stream_update_fragment_info()
    
    The gst_dash_demux_stream_update_fragment_info function could call
    gst_dash_demux_stream_update_headers_info function twice. The
    gst_dash_demux_stream_update_headers_info function will set header_uri and
    index_uri to some newly allocated strings. The values set by the first call of
    gst_dash_demux_stream_update_headers_info will leak when the function is
    called for a second time.
    
    The solution is to call gst_adaptive_demux_stream_fragment_clear before the
    second call of gst_dash_demux_stream_update_headers_info
    
    https://bugzilla.gnome.org/show_bug.cgi?id=753188