From 148f867c120fbde2ed5a92a8f89ef30a805eb61c Mon Sep 17 00:00:00 2001 From: Hyunjun Ko Date: Fri, 15 Sep 2017 15:14:47 +0900 Subject: [PATCH] vaapiencode/libs: encoder: fix leaks of properties https://bugzilla.gnome.org/show_bug.cgi?id=786321 --- gst-libs/gst/vaapi/gstvaapiencoder.c | 2 ++ gst/vaapi/gstvaapiencode.c | 1 + 2 files changed, 3 insertions(+) diff --git a/gst-libs/gst/vaapi/gstvaapiencoder.c b/gst-libs/gst/vaapi/gstvaapiencoder.c index 8fb60b79df..a05de4288b 100644 --- a/gst-libs/gst/vaapi/gstvaapiencoder.c +++ b/gst-libs/gst/vaapi/gstvaapiencoder.c @@ -1263,6 +1263,8 @@ gst_vaapi_encoder_init_properties (GstVaapiEncoder * encoder) NULL) != GST_VAAPI_ENCODER_STATUS_SUCCESS) return FALSE; } + + g_ptr_array_unref (props); return TRUE; } diff --git a/gst/vaapi/gstvaapiencode.c b/gst/vaapi/gstvaapiencode.c index b3988394a9..27a807afec 100644 --- a/gst/vaapi/gstvaapiencode.c +++ b/gst/vaapi/gstvaapiencode.c @@ -939,6 +939,7 @@ gst_vaapiencode_init_properties (GstVaapiEncode * encode) return FALSE; g_ptr_array_add (encode->prop_values, prop_value); } + g_ptr_array_unref (props); return TRUE; }