gst: Clear floating flag in constructor of all GstObject subclasses that are not owned by any parent

https://bugzilla.gnome.org/show_bug.cgi?id=743062
This commit is contained in:
Sebastian Dröge 2017-05-15 19:51:47 +03:00
parent defbe06d0e
commit 2c6016667b
2 changed files with 2 additions and 0 deletions

View file

@ -639,6 +639,7 @@ gst_v4l2_allocator_new (GstObject * parent, gint video_fd,
g_free (parent_name);
allocator = g_object_new (GST_TYPE_V4L2_ALLOCATOR, "name", name, NULL);
gst_object_ref_sink (allocator);
g_free (name);
/* Save everything */

View file

@ -1589,6 +1589,7 @@ gst_v4l2_buffer_pool_new (GstV4l2Object * obj, GstCaps * caps)
pool = (GstV4l2BufferPool *) g_object_new (GST_TYPE_V4L2_BUFFER_POOL,
"name", name, NULL);
g_object_ref_sink (pool);
g_free (name);
gst_poll_fd_init (&pool->pollfd);