From 1f245c3d2ef51a749b9585979dd32b9dc086c4f0 Mon Sep 17 00:00:00 2001 From: Vineeth TM Date: Thu, 12 Nov 2015 16:02:45 +0900 Subject: [PATCH] glcolorconvert: Fix frag_prog and frag_body memory leak https://bugzilla.gnome.org/show_bug.cgi?id=757974 --- gst-libs/gst/gl/gstglcolorconvert.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gst-libs/gst/gl/gstglcolorconvert.c b/gst-libs/gst/gl/gstglcolorconvert.c index abd817c64f..ef44827497 100644 --- a/gst-libs/gst/gl/gstglcolorconvert.c +++ b/gst-libs/gst/gl/gstglcolorconvert.c @@ -529,6 +529,14 @@ gst_gl_color_convert_reset (GstGLColorConvert * convert) convert->priv->convert_info.chroma_sampling[0] = 1.0f; convert->priv->convert_info.chroma_sampling[1] = 1.0f; + if (convert->priv->convert_info.frag_prog) { + g_free (convert->priv->convert_info.frag_prog); + convert->priv->convert_info.frag_prog = NULL; + } + if (convert->priv->convert_info.frag_body) { + g_free (convert->priv->convert_info.frag_body); + convert->priv->convert_info.frag_body = NULL; + } if (convert->shader) { gst_object_unref (convert->shader); convert->shader = NULL;