glmixer: pass the proper free function to frames and buffers array

'array_buffers' contain borrowed GstBuffer and so shouldn't have a free
function. 'frames' is the one containing GstGLMixerFrameData and so should use
_free_glmixer_frame_data as free function.

Fix GstGLMixerFrameData leaks with the
validate.file.glvideomixer.simple.play_15s.synchronized scenario.

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

Signed-off-by: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
This commit is contained in:
Guillaume Desmottes 2015-04-15 15:16:33 +02:00 committed by Vincent Penquerc'h
parent 917c395403
commit 481b1c921e

View file

@ -745,9 +745,9 @@ gst_gl_mixer_start (GstAggregator * agg)
GstElement *element = GST_ELEMENT (agg);
GST_OBJECT_LOCK (mix);
mix->array_buffers = g_ptr_array_new_full (element->numsinkpads,
mix->array_buffers = g_ptr_array_new_full (element->numsinkpads, NULL);
mix->frames = g_ptr_array_new_full (element->numsinkpads,
(GDestroyNotify) _free_glmixer_frame_data);
mix->frames = g_ptr_array_new_full (element->numsinkpads, NULL);
g_ptr_array_set_size (mix->array_buffers, element->numsinkpads);
g_ptr_array_set_size (mix->frames, element->numsinkpads);