mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-29 19:50:40 +00:00
ges-uri-asset: Fix GESDiscovererManager leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5552>
This commit is contained in:
parent
2dd65d8715
commit
8f18fde21a
1 changed files with 7 additions and 2 deletions
|
@ -712,10 +712,13 @@ void
|
|||
ges_uri_clip_asset_class_set_timeout (GESUriClipAssetClass * klass,
|
||||
GstClockTime timeout)
|
||||
{
|
||||
GESDiscovererManager *manager;
|
||||
|
||||
g_return_if_fail (GES_IS_URI_CLIP_ASSET_CLASS (klass));
|
||||
|
||||
ges_discoverer_manager_set_timeout (ges_discoverer_manager_get_default (),
|
||||
timeout);
|
||||
manager = ges_discoverer_manager_get_default ();
|
||||
ges_discoverer_manager_set_timeout (manager, timeout);
|
||||
gst_object_unref (manager);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -921,6 +924,8 @@ _ges_uri_asset_ensure_setup (gpointer uriasset_class)
|
|||
g_signal_connect (manager, "discovered",
|
||||
G_CALLBACK (discoverer_discovered_cb), NULL);
|
||||
|
||||
gst_object_unref (manager);
|
||||
|
||||
discoverer = gst_discoverer_new (timeout, &err);
|
||||
if (!discoverer) {
|
||||
GST_ERROR ("Could not create discoverer: %s", err->message);
|
||||
|
|
Loading…
Reference in a new issue