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 737762 - baseparse: leaks caps in gst_base_parse_process_streamheader
baseparse: leaks caps in gst_base_parse_process_streamheader
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other All
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-10-02 01:32 UTC by Matej Knopp
Modified: 2014-10-03 11:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch (868 bytes, patch)
2014-10-02 01:32 UTC, Matej Knopp
committed Details | Review
baseparse set_sink_caps shouldn't take ownership of the caps (740 bytes, patch)
2014-10-03 11:15 UTC, Matej Knopp
committed Details | Review

Description Matej Knopp 2014-10-02 01:32:48 UTC
Created attachment 287561 [details] [review]
Patch

.
Comment 1 Sebastian Dröge (slomo) 2014-10-02 07:40:54 UTC
commit 5e8b4bf085180f7a4c7ae6ec0f525baeaedd4df8
Author: Matej Knopp <matej.knopp@gmail.com>
Date:   Thu Oct 2 03:30:24 2014 +0200

    baseparse: don't leak caps in gst_base_parse_process_streamheader
    
    https://bugzilla.gnome.org/show_bug.cgi?id=737762
Comment 2 Tim-Philipp Müller 2014-10-03 08:45:04 UTC
I have reverted this

commit c78a1b111ce48fb1c161d4f4e7ed445e10ef1309
Author: Tim-Philipp Müller <tim@centricular.com>
Date:   Fri Oct 3 09:01:15 2014 +0100

    Revert "baseparse: don't leak caps in gst_base_parse_process_streamheader"
    
    This reverts commit 5e8b4bf085180f7a4c7ae6ec0f525baeaedd4df8.
    
    This causes refcounting criticals in the baseparse unit test.
Comment 3 Tim-Philipp Müller 2014-10-03 08:45:48 UTC
Comment on attachment 287561 [details] [review]
Patch

Note that the patch might be right, but exposing a bug elsewhere. I did not investigate. But it clearly breaks stuff.
Comment 4 Matej Knopp 2014-10-03 11:12:44 UTC
Looks like gst_parser_tester_set_sink_caps takes ownershp of the caps, which it probably shouldn't.
Comment 5 Matej Knopp 2014-10-03 11:15:36 UTC
Created attachment 287663 [details] [review]
baseparse set_sink_caps shouldn't take ownership of the caps

This fixes the test.
Comment 6 Tim-Philipp Müller 2014-10-03 11:42:57 UTC
Bug in the unit test as you say, thanks for investigating!

commit d8aac32c787c8896a92224c6ac47a1a439dc579a
Author: Matej Knopp <matej.knopp@gmail.com>
Date:   Thu Oct 2 03:30:24 2014 +0200

    baseparse: don't leak caps in gst_base_parse_process_streamheader
    
    https://bugzilla.gnome.org/show_bug.cgi?id=737762

commit c497f629bc75aa04c426afe7124d9da078b3599d
Author: Matej Knopp <matej.knopp@gmail.com>
Date:   Fri Oct 3 13:14:25 2014 +0200

    tests: baseparse: set_sink_caps vfunc should't take ownership of the caps
    
    https://bugzilla.gnome.org/show_bug.cgi?id=737762