From: Seungha Yang Date: Fri, 8 Feb 2019 12:38:04 +0000 (+0900) Subject: glupload: Don't leak caps features X-Git-Tag: 1.19.3~511^2~1239 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3152cbb46e34950cce55007651ca62c967607686;p=platform%2Fupstream%2Fgstreamer.git glupload: Don't leak caps features Create caps features when it is required. --- diff --git a/gst-libs/gst/gl/gstglupload.c b/gst-libs/gst/gl/gstglupload.c index f1108f4be1..c10c0230f5 100644 --- a/gst-libs/gst/gl/gstglupload.c +++ b/gst-libs/gst/gl/gstglupload.c @@ -518,9 +518,7 @@ _dma_buf_upload_transform_caps (gpointer impl, GstGLContext * context, GstPadDirection direction, GstCaps * caps) { struct DmabufUpload *dmabuf = impl; - GstCapsFeatures *passthrough = - gst_caps_features_from_string - (GST_CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION); + GstCapsFeatures *passthrough; GstCaps *ret; if (context) { @@ -532,6 +530,9 @@ _dma_buf_upload_transform_caps (gpointer impl, GstGLContext * context, return NULL; } + passthrough = gst_caps_features_from_string + (GST_CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION); + if (direction == GST_PAD_SINK) { GstCaps *tmp;