[Bug 766661] gltestsrc,glmosaic: fix shader leaks

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Thu May 19 14:16:15 UTC 2016


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

--- Comment #3 from Guillaume Desmottes <gdesmott at gnome.org> ---
Created attachment 328192
  --> https://bugzilla.gnome.org/attachment.cgi?id=328192&action=edit
gltestsrc: fix shaders ref counting

The gltestsrc element uses two shaders: color_shader and snow_shader.
Those are alternatively assigned to the SrcShader->shader pointer and
their reference was transferred to it. Only the SrcShader->shader was
unreffed (in _src_shader_deinit()) so only one shader was properly
freed, the other one was leaked.

Fixed this by giving an extra ref to SrcShader->shader and unreffing the
2 shaders in _src_smpte_free().

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