Fix leaks

Add some docs
Add properties to loop objects for future use
This commit is contained in:
Wim Taymans 2017-08-08 18:22:44 +02:00
parent 600055bd68
commit eeda53dbef
25 changed files with 92 additions and 53 deletions

View file

@ -426,7 +426,7 @@ gst_pipewire_device_provider_probe (GstDeviceProvider * provider)
GST_DEBUG_OBJECT (self, "starting probe");
if (!(l = pw_loop_new ()))
if (!(l = pw_loop_new (NULL)))
return NULL;
if (!(c = pw_core_new (l, NULL)))
@ -503,7 +503,7 @@ gst_pipewire_device_provider_start (GstDeviceProvider * provider)
GST_DEBUG_OBJECT (self, "starting provider");
self->loop = pw_loop_new ();
self->loop = pw_loop_new (NULL);
self->list_only = FALSE;
if (!(self->main_loop = pw_thread_loop_new (self->loop, "pipewire-device-monitor"))) {
@ -590,6 +590,8 @@ gst_pipewire_device_provider_stop (GstDeviceProvider * provider)
{
GstPipeWireDeviceProvider *self = GST_PIPEWIRE_DEVICE_PROVIDER (provider);
GST_DEBUG_OBJECT (self, "stopping provider");
if (self->remote) {
pw_remote_disconnect (self->remote);
pw_remote_destroy (self->remote);

View file

@ -302,7 +302,7 @@ gst_pipewire_sink_init (GstPipeWireSink * sink)
g_queue_init (&sink->queue);
sink->loop = pw_loop_new ();
sink->loop = pw_loop_new (NULL);
sink->main_loop = pw_thread_loop_new (sink->loop, "pipewire-sink-loop");
sink->core = pw_core_new (sink->loop, NULL);
sink->type = pw_core_get_type (sink->core);

View file

@ -308,7 +308,7 @@ gst_pipewire_src_init (GstPipeWireSrc * src)
src->client_name = pw_get_client_name ();
src->buf_ids = g_hash_table_new_full (g_direct_hash, g_direct_equal, NULL, (GDestroyNotify) gst_buffer_unref);
src->loop = pw_loop_new ();
src->loop = pw_loop_new (NULL);
src->main_loop = pw_thread_loop_new (src->loop, "pipewire-main-loop");
src->core = pw_core_new (src->loop, NULL);
src->type = pw_core_get_type (src->core);