launch: Ensure to add required ref to profiles from project
authorThibault Saunier <tsaunier@igalia.com>
Tue, 5 Jan 2021 14:52:15 +0000 (11:52 -0300)
committerThibault Saunier <tsaunier@igalia.com>
Tue, 5 Jan 2021 14:52:43 +0000 (11:52 -0300)
We were unreffing something we were not owning

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/224>

tools/ges-launcher.c

index 2549c9d..cf56b83 100644 (file)
@@ -493,6 +493,9 @@ _set_rendering_details (GESLauncher * self)
                     gst_encoding_profile_get_name (profiles->data)) == 0)
               prof = profiles->data;
       }
+
+      if (prof)
+        prof = gst_object_ref (prof);
     }
 
     if (!prof) {