mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
multifile: drop use of GSlice
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3695>
This commit is contained in:
parent
e256472ca6
commit
56d3beed0b
3 changed files with 11 additions and 11 deletions
|
@ -203,7 +203,7 @@ static void
|
||||||
splitmux_part_free_queue_item (GstDataQueueItem * item)
|
splitmux_part_free_queue_item (GstDataQueueItem * item)
|
||||||
{
|
{
|
||||||
gst_mini_object_unref (item->object);
|
gst_mini_object_unref (item->object);
|
||||||
g_slice_free (GstDataQueueItem, item);
|
g_free (item);
|
||||||
}
|
}
|
||||||
|
|
||||||
static GstFlowReturn
|
static GstFlowReturn
|
||||||
|
@ -251,7 +251,7 @@ splitmux_part_pad_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
||||||
/* We are active, and one queue is empty, place this buffer in
|
/* We are active, and one queue is empty, place this buffer in
|
||||||
* the dataqueue */
|
* the dataqueue */
|
||||||
GST_LOG_OBJECT (reader, "Enqueueing buffer %" GST_PTR_FORMAT, buf);
|
GST_LOG_OBJECT (reader, "Enqueueing buffer %" GST_PTR_FORMAT, buf);
|
||||||
item = g_slice_new (GstDataQueueItem);
|
item = g_new (GstDataQueueItem, 1);
|
||||||
item->destroy = (GDestroyNotify) splitmux_part_free_queue_item;
|
item->destroy = (GDestroyNotify) splitmux_part_free_queue_item;
|
||||||
item->object = GST_MINI_OBJECT (buf);
|
item->object = GST_MINI_OBJECT (buf);
|
||||||
item->size = gst_buffer_get_size (buf);
|
item->size = gst_buffer_get_size (buf);
|
||||||
|
@ -341,7 +341,7 @@ enqueue_event (GstSplitMuxPartReader * reader, GstSplitMuxPartPad * part_pad,
|
||||||
GstDataQueueItem *item;
|
GstDataQueueItem *item;
|
||||||
|
|
||||||
GST_LOG_OBJECT (reader, "Enqueueing event %" GST_PTR_FORMAT, event);
|
GST_LOG_OBJECT (reader, "Enqueueing event %" GST_PTR_FORMAT, event);
|
||||||
item = g_slice_new (GstDataQueueItem);
|
item = g_new (GstDataQueueItem, 1);
|
||||||
item->destroy = (GDestroyNotify) splitmux_part_free_queue_item;
|
item->destroy = (GDestroyNotify) splitmux_part_free_queue_item;
|
||||||
item->object = GST_MINI_OBJECT (event);
|
item->object = GST_MINI_OBJECT (event);
|
||||||
item->size = 0;
|
item->size = 0;
|
||||||
|
|
|
@ -252,32 +252,32 @@ static GstClockTime calculate_next_max_timecode (GstSplitMuxSink * splitmux,
|
||||||
static MqStreamBuf *
|
static MqStreamBuf *
|
||||||
mq_stream_buf_new (void)
|
mq_stream_buf_new (void)
|
||||||
{
|
{
|
||||||
return g_slice_new0 (MqStreamBuf);
|
return g_new0 (MqStreamBuf, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
mq_stream_buf_free (MqStreamBuf * data)
|
mq_stream_buf_free (MqStreamBuf * data)
|
||||||
{
|
{
|
||||||
g_slice_free (MqStreamBuf, data);
|
g_free (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
static SplitMuxOutputCommand *
|
static SplitMuxOutputCommand *
|
||||||
out_cmd_buf_new (void)
|
out_cmd_buf_new (void)
|
||||||
{
|
{
|
||||||
return g_slice_new0 (SplitMuxOutputCommand);
|
return g_new0 (SplitMuxOutputCommand, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
out_cmd_buf_free (SplitMuxOutputCommand * data)
|
out_cmd_buf_free (SplitMuxOutputCommand * data)
|
||||||
{
|
{
|
||||||
g_slice_free (SplitMuxOutputCommand, data);
|
g_free (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
input_gop_free (InputGop * gop)
|
input_gop_free (InputGop * gop)
|
||||||
{
|
{
|
||||||
g_clear_pointer (&gop->start_tc, gst_video_time_code_free);
|
g_clear_pointer (&gop->start_tc, gst_video_time_code_free);
|
||||||
g_slice_free (InputGop, gop);
|
g_free (gop);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -2878,7 +2878,7 @@ handle_mq_input (GstPad * pad, GstPadProbeInfo * info, MqStreamCtx * ctx)
|
||||||
splitmux->fragment_start_time_pts = rtime;
|
splitmux->fragment_start_time_pts = rtime;
|
||||||
|
|
||||||
if (g_queue_is_empty (&splitmux->pending_input_gops)) {
|
if (g_queue_is_empty (&splitmux->pending_input_gops)) {
|
||||||
InputGop *gop = g_slice_new0 (InputGop);
|
InputGop *gop = g_new0 (InputGop, 1);
|
||||||
|
|
||||||
gop->from_gap = TRUE;
|
gop->from_gap = TRUE;
|
||||||
gop->start_time = rtime;
|
gop->start_time = rtime;
|
||||||
|
@ -3026,7 +3026,7 @@ handle_mq_input (GstPad * pad, GstPadProbeInfo * info, MqStreamCtx * ctx)
|
||||||
|
|
||||||
if (!gop || (!gop->from_gap
|
if (!gop || (!gop->from_gap
|
||||||
&& !GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_DELTA_UNIT))) {
|
&& !GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_DELTA_UNIT))) {
|
||||||
gop = g_slice_new0 (InputGop);
|
gop = g_new0 (InputGop, 1);
|
||||||
|
|
||||||
gop->start_time = running_time;
|
gop->start_time = running_time;
|
||||||
gop->start_time_pts = running_time_pts;
|
gop->start_time_pts = running_time_pts;
|
||||||
|
|
|
@ -810,7 +810,7 @@ gst_splitmux_pad_loop (GstPad * pad)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
g_slice_free (GstDataQueueItem, item);
|
g_free (item);
|
||||||
|
|
||||||
gst_object_unref (reader);
|
gst_object_unref (reader);
|
||||||
gst_object_unref (part_pad);
|
gst_object_unref (part_pad);
|
||||||
|
|
Loading…
Reference in a new issue