From daecc5bfa1e7141e504cd021fd7a63a518be7aec Mon Sep 17 00:00:00 2001 From: =?utf8?q?V=C3=ADctor=20Manuel=20J=C3=A1quez=20Leal?= Date: Wed, 8 Apr 2020 19:41:09 +0200 Subject: [PATCH] vaapipostproc: early return if fixate srcpad caps fails Part-of: --- gst/vaapi/gstvaapipostproc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gst/vaapi/gstvaapipostproc.c b/gst/vaapi/gstvaapipostproc.c index 62e0dda..5f7d9cd 100644 --- a/gst/vaapi/gstvaapipostproc.c +++ b/gst/vaapi/gstvaapipostproc.c @@ -1486,13 +1486,16 @@ gst_vaapipostproc_fixate_caps (GstBaseTransform * trans, outcaps = gst_vaapipostproc_fixate_srccaps (postproc, caps, othercaps); g_mutex_unlock (&postproc->postproc_lock); + if (!outcaps) + goto done; /* set passthrough according to caps changes or filter changes */ same_caps = gst_caps_is_equal (caps, outcaps); gst_base_transform_set_passthrough (trans, same_caps && !filter_updated); done: - GST_DEBUG_OBJECT (trans, "fixated othercaps to %" GST_PTR_FORMAT, outcaps); + if (outcaps) + GST_DEBUG_OBJECT (trans, "fixated othercaps to %" GST_PTR_FORMAT, outcaps); gst_caps_unref (othercaps); return outcaps; -- 2.7.4