From cc80ab6b2e2224bca2871851ef8aa05307cc5a0c Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Mon, 12 Mar 2012 12:22:54 +0100 Subject: [PATCH] tests: fix for caps _normalize changes --- tests/examples/encoding/gstcapslist.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tests/examples/encoding/gstcapslist.c b/tests/examples/encoding/gstcapslist.c index aed5821a31..1e59635214 100644 --- a/tests/examples/encoding/gstcapslist.c +++ b/tests/examples/encoding/gstcapslist.c @@ -88,7 +88,7 @@ clear_caps (GstCaps * caps, GstCaps * rescaps) static GstCaps * get_all_caps (GList * elements, GstPadDirection direction) { - GstCaps *res = NULL, *res2; + GstCaps *res; GList *tmp; res = gst_caps_new_empty (); @@ -106,9 +106,9 @@ get_all_caps (GList * elements, GstPadDirection direction) } } - res2 = gst_caps_normalize (res); - gst_caps_unref (res); - return res2; + res = gst_caps_normalize (res); + + return res; } /** @@ -278,8 +278,7 @@ beach: if (!hadcodecs) gst_caps_unref (codecformats); - tmpcaps = gst_caps_normalize (res); - gst_caps_unref (res); + res = gst_caps_normalize (res); - return tmpcaps; + return res; }