diff --git a/gst/mpegpsmux/mpegpsmux.c b/gst/mpegpsmux/mpegpsmux.c index fdd1c14933..cdd3681d23 100644 --- a/gst/mpegpsmux/mpegpsmux.c +++ b/gst/mpegpsmux/mpegpsmux.c @@ -341,6 +341,7 @@ mpegpsmux_create_stream (MpegPsMux * mux, MpegPsPadData * ps_data, GstPad * pad) } beach: + gst_caps_unref (caps); return ret; } diff --git a/tests/examples/directfb/gstdfb.c b/tests/examples/directfb/gstdfb.c index 32ddd154a3..5fcc0260a5 100644 --- a/tests/examples/directfb/gstdfb.c +++ b/tests/examples/directfb/gstdfb.c @@ -91,11 +91,14 @@ size_changed (GObject * obj, GParamSpec * pspec, IDirectFBWindow * window) gint width, height; if (!(gst_structure_get_int (s, "width", &width) && - gst_structure_get_int (s, "height", &height))) + gst_structure_get_int (s, "height", &height))) { + gst_caps_unref (caps); return; + } window->Resize (window, width, height); } + gst_caps_unref (caps); } static void