iterator: drop use of GSlice

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3695>
This commit is contained in:
Tim-Philipp Müller 2023-01-08 00:55:04 +00:00 committed by GStreamer Marge Bot
parent 6a0be7ea56
commit e190ff16cc

View file

@ -68,6 +68,7 @@
*/
#include "gst_private.h"
#include "glib-compat-private.h"
#include <gst/gstiterator.h>
/**
@ -83,7 +84,7 @@ gst_iterator_copy (const GstIterator * it)
{
GstIterator *copy;
copy = g_slice_copy (it->size, it);
copy = g_memdup2 (it, it->size);
if (it->copy)
it->copy (it, copy);
@ -159,7 +160,7 @@ gst_iterator_new (guint size,
g_return_val_if_fail (resync != NULL, NULL);
g_return_val_if_fail (free != NULL, NULL);
result = g_slice_alloc0 (size);
result = g_malloc0 (size);
gst_iterator_init (result, size, type, lock, master_cookie, copy, next, item,
resync, free);
@ -422,7 +423,7 @@ gst_iterator_free (GstIterator * it)
it->free (it);
g_slice_free1 (it->size, it);
g_free (it);
}
/**