diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2017-05-15 19:47:22 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2017-05-17 10:40:52 +0300 |
commit | 67fb3b12ee60c2219862bcd9821ab94a091fe069 (patch) | |
tree | 3c5a9e863bb41648085b715bb195cbae566a9a71 /sys | |
parent | 2a8784e218df35f1ec1699a59394974349aba67c (diff) | |
download | gst-plugins-base-67fb3b12ee60c2219862bcd9821ab94a091fe069.tar.gz gst-plugins-base-67fb3b12ee60c2219862bcd9821ab94a091fe069.tar.xz |
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
Diffstat (limited to 'sys')
-rw-r--r-- | sys/ximage/ximagepool.c | 2 | ||||
-rw-r--r-- | sys/xvimage/xvimageallocator.c | 1 | ||||
-rw-r--r-- | sys/xvimage/xvimagepool.c | 1 |
3 files changed, 4 insertions, 0 deletions
diff --git a/sys/ximage/ximagepool.c b/sys/ximage/ximagepool.c index 9e5539302..2f44c286d 100644 --- a/sys/ximage/ximagepool.c +++ b/sys/ximage/ximagepool.c @@ -675,8 +675,10 @@ gst_ximage_buffer_pool_new (GstXImageSink * ximagesink) g_return_val_if_fail (GST_IS_X_IMAGE_SINK (ximagesink), NULL); pool = g_object_new (GST_TYPE_XIMAGE_BUFFER_POOL, NULL); + gst_object_ref_sink (pool); pool->sink = gst_object_ref (ximagesink); pool->allocator = g_object_new (GST_TYPE_XIMAGE_MEMORY_ALLOCATOR, NULL); + gst_object_ref_sink (pool->allocator); GST_LOG_OBJECT (pool, "new XImage buffer pool %p", pool); diff --git a/sys/xvimage/xvimageallocator.c b/sys/xvimage/xvimageallocator.c index 3a2728c23..429c5aaa7 100644 --- a/sys/xvimage/xvimageallocator.c +++ b/sys/xvimage/xvimageallocator.c @@ -328,6 +328,7 @@ gst_xvimage_allocator_new (GstXvContext * context) alloc = g_object_new (GST_TYPE_XVIMAGE_ALLOCATOR, NULL); alloc->context = gst_xvcontext_ref (context); + gst_object_ref_sink (alloc); return alloc; } diff --git a/sys/xvimage/xvimagepool.c b/sys/xvimage/xvimagepool.c index 7203105aa..116c6d1dc 100644 --- a/sys/xvimage/xvimagepool.c +++ b/sys/xvimage/xvimagepool.c @@ -209,6 +209,7 @@ gst_xvimage_buffer_pool_new (GstXvImageAllocator * allocator) GstXvImageBufferPool *pool; pool = g_object_new (GST_TYPE_XVIMAGE_BUFFER_POOL, NULL); + gst_object_ref_sink (pool); pool->allocator = gst_object_ref (allocator); GST_LOG_OBJECT (pool, "new XvImage buffer pool %p", pool); |