From b5a28df0f312f6e603d0c729f9f799a25a1f0a87 Mon Sep 17 00:00:00 2001 From: Guillaume Desmottes Date: Thu, 16 Apr 2020 16:17:56 +0000 Subject: [PATCH] transcodebin: fix caps NULL unref gst_pad_get_current_caps() can return a NULL pointer which was raisin a CRITICAL. --- gst/transcode/gsttranscodebin.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst/transcode/gsttranscodebin.c b/gst/transcode/gsttranscodebin.c index 2df811f5ae..1a310af9e5 100644 --- a/gst/transcode/gsttranscodebin.c +++ b/gst/transcode/gsttranscodebin.c @@ -271,7 +271,7 @@ pad_added_cb (GstElement * decodebin, GstPad * pad, GstTranscodeBin * self) "sink-pad", GST_TYPE_PAD, sinkpad, "sink-caps", GST_TYPE_CAPS, othercaps, NULL)); - gst_caps_unref (caps); + gst_clear_caps (&caps); if (othercaps) gst_caps_unref (othercaps); }