validate: pad-monitor: fix caps leaks
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Tue, 7 Feb 2017 11:28:02 +0000 (12:28 +0100)
committerThibault Saunier <thibault.saunier@osg.samsung.com>
Wed, 8 Feb 2017 20:00:08 +0000 (17:00 -0300)
These caps were not released when disposing the pad monitor.

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

validate/gst/validate/gst-validate-pad-monitor.c

index ecf5cba..7a5e63f 100644 (file)
@@ -860,6 +860,8 @@ gst_validate_pad_monitor_dispose (GObject * object)
   g_list_free_full (monitor->expired_events, (GDestroyNotify) gst_event_unref);
   g_list_free_full (monitor->all_bufs, (GDestroyNotify) gst_buffer_unref);
   gst_caps_replace (&monitor->last_caps, NULL);
+  gst_caps_replace (&monitor->last_query_res, NULL);
+  gst_caps_replace (&monitor->last_query_filter, NULL);
 
   G_OBJECT_CLASS (parent_class)->dispose (object);
 }