mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-19 16:21:17 +00:00
segment: drop use of GSlice
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3695>
This commit is contained in:
parent
19a6468a53
commit
eeced74fce
1 changed files with 4 additions and 3 deletions
|
@ -20,6 +20,7 @@
|
|||
*/
|
||||
|
||||
#include "gst_private.h"
|
||||
#include "glib-compat-private.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
|
@ -103,7 +104,7 @@ gst_segment_copy (const GstSegment * segment)
|
|||
GstSegment *result = NULL;
|
||||
|
||||
if (segment) {
|
||||
result = (GstSegment *) g_slice_copy (sizeof (GstSegment), segment);
|
||||
result = (GstSegment *) g_memdup2 (segment, sizeof (GstSegment));
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
@ -139,7 +140,7 @@ gst_segment_new (void)
|
|||
{
|
||||
GstSegment *result;
|
||||
|
||||
result = g_slice_new0 (GstSegment);
|
||||
result = g_new0 (GstSegment, 1);
|
||||
gst_segment_init (result, GST_FORMAT_UNDEFINED);
|
||||
|
||||
return result;
|
||||
|
@ -154,7 +155,7 @@ gst_segment_new (void)
|
|||
void
|
||||
gst_segment_free (GstSegment * segment)
|
||||
{
|
||||
g_slice_free (GstSegment, segment);
|
||||
g_free (segment);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue