[196/906] fix a differencematte memory issue
authorFilippo Argiolas <filippo.argiolas@gmail.com>
Tue, 19 Aug 2008 07:48:14 +0000 (09:48 +0200)
committerMatthew Waters <ystreet00@gmail.com>
Sat, 15 Mar 2014 17:36:26 +0000 (18:36 +0100)
gst/gl/gstgldifferencematte.c

index f99bf05..6abf6e3 100644 (file)
@@ -140,8 +140,14 @@ gst_gl_differencematte_reset_gl_resources (GstGLFilter *filter)
   glDeleteTextures (1, &differencematte->newbgtexture);
   for (i=0; i<4; i++) {
     g_object_unref (differencematte->shader[i]);
+    differencematte->shader[i] = NULL;
     glDeleteTextures (1, &differencematte->midtexture[i]);
   }
+  differencematte->location = NULL;
+  differencematte->pixbuf = NULL;
+  differencematte->savedbgtexture = 0;
+  differencematte->newbgtexture = 0;
+  differencematte->bg_has_changed = FALSE;
 }
 
 static void