mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-30 02:58:24 +00:00
playback: drop use of GSlice
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3695>
This commit is contained in:
parent
a9c5a52b25
commit
165fdac5c6
7 changed files with 40 additions and 40 deletions
|
@ -1803,7 +1803,7 @@ analyze_new_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
||||||
capsfilter = delem->capsfilter =
|
capsfilter = delem->capsfilter =
|
||||||
gst_element_factory_make ("capsfilter", NULL);
|
gst_element_factory_make ("capsfilter", NULL);
|
||||||
} else {
|
} else {
|
||||||
delem = g_slice_new0 (GstDecodeElement);
|
delem = g_new0 (GstDecodeElement, 1);
|
||||||
capsfilter = delem->element =
|
capsfilter = delem->element =
|
||||||
gst_element_factory_make ("capsfilter", NULL);
|
gst_element_factory_make ("capsfilter", NULL);
|
||||||
delem->capsfilter = NULL;
|
delem->capsfilter = NULL;
|
||||||
|
@ -1936,7 +1936,7 @@ setup_caps_delay:
|
||||||
CHAIN_MUTEX_LOCK (chain);
|
CHAIN_MUTEX_LOCK (chain);
|
||||||
GST_LOG_OBJECT (dbin, "Chain %p has now %d dynamic pads", chain,
|
GST_LOG_OBJECT (dbin, "Chain %p has now %d dynamic pads", chain,
|
||||||
g_list_length (chain->pending_pads));
|
g_list_length (chain->pending_pads));
|
||||||
ppad = g_slice_new0 (GstPendingPad);
|
ppad = g_new0 (GstPendingPad, 1);
|
||||||
ppad->pad = gst_object_ref (pad);
|
ppad->pad = gst_object_ref (pad);
|
||||||
ppad->chain = chain;
|
ppad->chain = chain;
|
||||||
ppad->event_probe_id =
|
ppad->event_probe_id =
|
||||||
|
@ -2403,7 +2403,7 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstDecodePad * dpad,
|
||||||
GST_LOG_OBJECT (dbin, "linked on pad %s:%s", GST_DEBUG_PAD_NAME (pad));
|
GST_LOG_OBJECT (dbin, "linked on pad %s:%s", GST_DEBUG_PAD_NAME (pad));
|
||||||
|
|
||||||
CHAIN_MUTEX_LOCK (chain);
|
CHAIN_MUTEX_LOCK (chain);
|
||||||
delem = g_slice_new0 (GstDecodeElement);
|
delem = g_new0 (GstDecodeElement, 1);
|
||||||
delem->element = gst_object_ref (element);
|
delem->element = gst_object_ref (element);
|
||||||
delem->capsfilter = NULL;
|
delem->capsfilter = NULL;
|
||||||
chain->elements = g_list_prepend (chain->elements, delem);
|
chain->elements = g_list_prepend (chain->elements, delem);
|
||||||
|
@ -2620,7 +2620,7 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstDecodePad * dpad,
|
||||||
gst_element_set_state (tmp, GST_STATE_NULL);
|
gst_element_set_state (tmp, GST_STATE_NULL);
|
||||||
|
|
||||||
gst_object_unref (tmp);
|
gst_object_unref (tmp);
|
||||||
g_slice_free (GstDecodeElement, dtmp);
|
g_free (dtmp);
|
||||||
|
|
||||||
chain->elements = g_list_delete_link (chain->elements, chain->elements);
|
chain->elements = g_list_delete_link (chain->elements, chain->elements);
|
||||||
} while (tmp != element);
|
} while (tmp != element);
|
||||||
|
@ -3364,7 +3364,7 @@ gst_decode_chain_unref (GstDecodeChain * chain)
|
||||||
{
|
{
|
||||||
if (g_atomic_int_dec_and_test (&chain->refs)) {
|
if (g_atomic_int_dec_and_test (&chain->refs)) {
|
||||||
g_mutex_clear (&chain->lock);
|
g_mutex_clear (&chain->lock);
|
||||||
g_slice_free (GstDecodeChain, chain);
|
g_free (chain);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3463,7 +3463,7 @@ gst_decode_chain_free_internal (GstDecodeChain * chain, gboolean hide)
|
||||||
gst_object_unref (element);
|
gst_object_unref (element);
|
||||||
l->data = NULL;
|
l->data = NULL;
|
||||||
|
|
||||||
g_slice_free (GstDecodeElement, delem);
|
g_free (delem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!hide) {
|
if (!hide) {
|
||||||
|
@ -3542,7 +3542,7 @@ static GstDecodeChain *
|
||||||
gst_decode_chain_new (GstDecodeBin * dbin, GstDecodeGroup * parent,
|
gst_decode_chain_new (GstDecodeBin * dbin, GstDecodeGroup * parent,
|
||||||
GstPad * pad)
|
GstPad * pad)
|
||||||
{
|
{
|
||||||
GstDecodeChain *chain = g_slice_new0 (GstDecodeChain);
|
GstDecodeChain *chain = g_new0 (GstDecodeChain, 1);
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (dbin, "Creating new chain %p with parent group %p", chain,
|
GST_DEBUG_OBJECT (dbin, "Creating new chain %p with parent group %p", chain,
|
||||||
parent);
|
parent);
|
||||||
|
@ -3666,7 +3666,7 @@ gst_decode_group_free_internal (GstDecodeGroup * group, gboolean hide)
|
||||||
GST_DEBUG_OBJECT (group->dbin, "%s group %p", (hide ? "Hid" : "Freed"),
|
GST_DEBUG_OBJECT (group->dbin, "%s group %p", (hide ? "Hid" : "Freed"),
|
||||||
group);
|
group);
|
||||||
if (!hide)
|
if (!hide)
|
||||||
g_slice_free (GstDecodeGroup, group);
|
g_free (group);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* gst_decode_group_free:
|
/* gst_decode_group_free:
|
||||||
|
@ -3846,7 +3846,7 @@ decodebin_set_queue_size_full (GstDecodeBin * dbin, GstElement * multiqueue,
|
||||||
static GstDecodeGroup *
|
static GstDecodeGroup *
|
||||||
gst_decode_group_new (GstDecodeBin * dbin, GstDecodeChain * parent)
|
gst_decode_group_new (GstDecodeBin * dbin, GstDecodeChain * parent)
|
||||||
{
|
{
|
||||||
GstDecodeGroup *group = g_slice_new0 (GstDecodeGroup);
|
GstDecodeGroup *group = g_new0 (GstDecodeGroup, 1);
|
||||||
GstElement *mq;
|
GstElement *mq;
|
||||||
gboolean seekable;
|
gboolean seekable;
|
||||||
|
|
||||||
|
@ -3889,7 +3889,7 @@ missing_multiqueue:
|
||||||
gst_missing_element_message_new (GST_ELEMENT_CAST (dbin),
|
gst_missing_element_message_new (GST_ELEMENT_CAST (dbin),
|
||||||
"multiqueue"));
|
"multiqueue"));
|
||||||
GST_ELEMENT_ERROR (dbin, CORE, MISSING_PLUGIN, (NULL), ("no multiqueue!"));
|
GST_ELEMENT_ERROR (dbin, CORE, MISSING_PLUGIN, (NULL), ("no multiqueue!"));
|
||||||
g_slice_free (GstDecodeGroup, group);
|
g_free (group);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -5231,7 +5231,7 @@ gst_pending_pad_free (GstPendingPad * ppad)
|
||||||
if (ppad->notify_caps_id)
|
if (ppad->notify_caps_id)
|
||||||
g_signal_handler_disconnect (ppad->pad, ppad->notify_caps_id);
|
g_signal_handler_disconnect (ppad->pad, ppad->notify_caps_id);
|
||||||
gst_object_unref (ppad->pad);
|
gst_object_unref (ppad->pad);
|
||||||
g_slice_free (GstPendingPad, ppad);
|
g_free (ppad);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****
|
/*****
|
||||||
|
|
|
@ -1586,7 +1586,7 @@ setup_caps_delay:
|
||||||
CHAIN_MUTEX_LOCK (chain);
|
CHAIN_MUTEX_LOCK (chain);
|
||||||
GST_LOG_OBJECT (parsebin, "Chain %p has now %d dynamic pads", chain,
|
GST_LOG_OBJECT (parsebin, "Chain %p has now %d dynamic pads", chain,
|
||||||
g_list_length (chain->pending_pads));
|
g_list_length (chain->pending_pads));
|
||||||
ppad = g_slice_new0 (GstPendingPad);
|
ppad = g_new0 (GstPendingPad, 1);
|
||||||
ppad->pad = gst_object_ref (pad);
|
ppad->pad = gst_object_ref (pad);
|
||||||
ppad->chain = chain;
|
ppad->chain = chain;
|
||||||
ppad->event_probe_id =
|
ppad->event_probe_id =
|
||||||
|
@ -2022,7 +2022,7 @@ connect_pad (GstParseBin * parsebin, GstElement * src, GstParsePad * parsepad,
|
||||||
GST_LOG_OBJECT (parsebin, "linked on pad %s:%s", GST_DEBUG_PAD_NAME (pad));
|
GST_LOG_OBJECT (parsebin, "linked on pad %s:%s", GST_DEBUG_PAD_NAME (pad));
|
||||||
|
|
||||||
CHAIN_MUTEX_LOCK (chain);
|
CHAIN_MUTEX_LOCK (chain);
|
||||||
pelem = g_slice_new0 (GstParseElement);
|
pelem = g_new0 (GstParseElement, 1);
|
||||||
pelem->element = gst_object_ref (element);
|
pelem->element = gst_object_ref (element);
|
||||||
pelem->capsfilter = NULL;
|
pelem->capsfilter = NULL;
|
||||||
chain->elements = g_list_prepend (chain->elements, pelem);
|
chain->elements = g_list_prepend (chain->elements, pelem);
|
||||||
|
@ -2191,7 +2191,7 @@ connect_pad (GstParseBin * parsebin, GstElement * src, GstParsePad * parsepad,
|
||||||
gst_element_set_state (tmp, GST_STATE_NULL);
|
gst_element_set_state (tmp, GST_STATE_NULL);
|
||||||
|
|
||||||
gst_object_unref (tmp);
|
gst_object_unref (tmp);
|
||||||
g_slice_free (GstParseElement, dtmp);
|
g_free (dtmp);
|
||||||
|
|
||||||
chain->elements = g_list_delete_link (chain->elements, chain->elements);
|
chain->elements = g_list_delete_link (chain->elements, chain->elements);
|
||||||
} while (tmp != element);
|
} while (tmp != element);
|
||||||
|
@ -2771,7 +2771,7 @@ gst_parse_chain_free_internal (GstParseChain * chain, gboolean hide)
|
||||||
gst_object_unref (element);
|
gst_object_unref (element);
|
||||||
l->data = NULL;
|
l->data = NULL;
|
||||||
|
|
||||||
g_slice_free (GstParseElement, pelem);
|
g_free (pelem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!hide) {
|
if (!hide) {
|
||||||
|
@ -2830,7 +2830,7 @@ gst_parse_chain_free_internal (GstParseChain * chain, gboolean hide)
|
||||||
|
|
||||||
if (!hide) {
|
if (!hide) {
|
||||||
g_mutex_clear (&chain->lock);
|
g_mutex_clear (&chain->lock);
|
||||||
g_slice_free (GstParseChain, chain);
|
g_free (chain);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2859,7 +2859,7 @@ static GstParseChain *
|
||||||
gst_parse_chain_new (GstParseBin * parsebin, GstParseGroup * parent,
|
gst_parse_chain_new (GstParseBin * parsebin, GstParseGroup * parent,
|
||||||
GstPad * pad, GstCaps * start_caps)
|
GstPad * pad, GstCaps * start_caps)
|
||||||
{
|
{
|
||||||
GstParseChain *chain = g_slice_new0 (GstParseChain);
|
GstParseChain *chain = g_new0 (GstParseChain, 1);
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (parsebin, "Creating new chain %p with parent group %p",
|
GST_DEBUG_OBJECT (parsebin, "Creating new chain %p with parent group %p",
|
||||||
chain, parent);
|
chain, parent);
|
||||||
|
@ -2900,7 +2900,7 @@ gst_parse_group_free_internal (GstParseGroup * group, gboolean hide)
|
||||||
GST_DEBUG_OBJECT (group->parsebin, "%s group %p", (hide ? "Hid" : "Freed"),
|
GST_DEBUG_OBJECT (group->parsebin, "%s group %p", (hide ? "Hid" : "Freed"),
|
||||||
group);
|
group);
|
||||||
if (!hide)
|
if (!hide)
|
||||||
g_slice_free (GstParseGroup, group);
|
g_free (group);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* gst_parse_group_free:
|
/* gst_parse_group_free:
|
||||||
|
@ -3009,7 +3009,7 @@ gst_parse_chain_start_free_hidden_groups_thread (GstParseChain * chain)
|
||||||
static GstParseGroup *
|
static GstParseGroup *
|
||||||
gst_parse_group_new (GstParseBin * parsebin, GstParseChain * parent)
|
gst_parse_group_new (GstParseBin * parsebin, GstParseChain * parent)
|
||||||
{
|
{
|
||||||
GstParseGroup *group = g_slice_new0 (GstParseGroup);
|
GstParseGroup *group = g_new0 (GstParseGroup, 1);
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (parsebin, "Creating new group %p with parent chain %p",
|
GST_DEBUG_OBJECT (parsebin, "Creating new group %p with parent chain %p",
|
||||||
group, parent);
|
group, parent);
|
||||||
|
@ -4294,7 +4294,7 @@ gst_pending_pad_free (GstPendingPad * ppad)
|
||||||
if (ppad->notify_caps_id)
|
if (ppad->notify_caps_id)
|
||||||
g_signal_handler_disconnect (ppad->pad, ppad->notify_caps_id);
|
g_signal_handler_disconnect (ppad->pad, ppad->notify_caps_id);
|
||||||
gst_object_unref (ppad->pad);
|
gst_object_unref (ppad->pad);
|
||||||
g_slice_free (GstPendingPad, ppad);
|
g_free (ppad);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****
|
/*****
|
||||||
|
|
|
@ -3959,7 +3959,7 @@ avelements_free (gpointer avelement)
|
||||||
gst_object_unref (elm->dec);
|
gst_object_unref (elm->dec);
|
||||||
if (elm->sink)
|
if (elm->sink)
|
||||||
gst_object_unref (elm->sink);
|
gst_object_unref (elm->sink);
|
||||||
g_slice_free (GstAVElement, elm);
|
g_free (elm);
|
||||||
}
|
}
|
||||||
|
|
||||||
static gint
|
static gint
|
||||||
|
@ -4085,7 +4085,7 @@ avelements_create (GstPlayBin * playbin, gboolean isaudioelement)
|
||||||
if (n_common_cf < 1)
|
if (n_common_cf < 1)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
ave = g_slice_new (GstAVElement);
|
ave = g_new (GstAVElement, 1);
|
||||||
ave->dec = gst_object_ref (d_factory);
|
ave->dec = gst_object_ref (d_factory);
|
||||||
ave->sink = gst_object_ref (s_factory);
|
ave->sink = gst_object_ref (s_factory);
|
||||||
ave->n_comm_cf = n_common_cf;
|
ave->n_comm_cf = n_common_cf;
|
||||||
|
@ -4146,7 +4146,7 @@ create_decoders_list (GList * factory_list, GSequence * avelements,
|
||||||
g_sequence_lookup (avelements, factory,
|
g_sequence_lookup (avelements, factory,
|
||||||
(GCompareDataFunc) avelement_lookup_decoder, NULL);
|
(GCompareDataFunc) avelement_lookup_decoder, NULL);
|
||||||
if (!seq_iter) {
|
if (!seq_iter) {
|
||||||
GstAVElement *ave = g_slice_new0 (GstAVElement);
|
GstAVElement *ave = g_new0 (GstAVElement, 1);
|
||||||
|
|
||||||
ave->dec = factory;
|
ave->dec = factory;
|
||||||
ave->sink = NULL;
|
ave->sink = NULL;
|
||||||
|
@ -4196,7 +4196,7 @@ create_decoders_list (GList * factory_list, GSequence * avelements,
|
||||||
gst_plugin_feature_list_free (factory_list);
|
gst_plugin_feature_list_free (factory_list);
|
||||||
|
|
||||||
for (tmp = ave_free_list; tmp; tmp = tmp->next)
|
for (tmp = ave_free_list; tmp; tmp = tmp->next)
|
||||||
g_slice_free (GstAVElement, tmp->data);
|
g_free (tmp->data);
|
||||||
g_list_free (ave_free_list);
|
g_list_free (ave_free_list);
|
||||||
|
|
||||||
dec_list = g_list_reverse (dec_list);
|
dec_list = g_list_reverse (dec_list);
|
||||||
|
|
|
@ -2237,7 +2237,7 @@ static void
|
||||||
control_source_pad (GstPlayBin3 * playbin, GstPad * pad,
|
control_source_pad (GstPlayBin3 * playbin, GstPad * pad,
|
||||||
GstPad * combine_pad, GstStreamType stream_type)
|
GstPad * combine_pad, GstStreamType stream_type)
|
||||||
{
|
{
|
||||||
SourcePad *sourcepad = g_slice_new0 (SourcePad);
|
SourcePad *sourcepad = g_new0 (SourcePad, 1);
|
||||||
|
|
||||||
sourcepad->pad = pad;
|
sourcepad->pad = pad;
|
||||||
sourcepad->event_probe_id =
|
sourcepad->event_probe_id =
|
||||||
|
@ -2415,7 +2415,7 @@ release_source_pad (GstPlayBin3 * playbin,
|
||||||
|
|
||||||
/* Remove from list of controlled pads and check again for EOS status */
|
/* Remove from list of controlled pads and check again for EOS status */
|
||||||
playbin->source_pads = g_list_remove (playbin->source_pads, sourcepad);
|
playbin->source_pads = g_list_remove (playbin->source_pads, sourcepad);
|
||||||
g_slice_free (SourcePad, sourcepad);
|
g_free (sourcepad);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* this function is called when a new pad is added to decodebin. We check the
|
/* this function is called when a new pad is added to decodebin. We check the
|
||||||
|
|
|
@ -105,7 +105,7 @@ gst_syncstream_unref (GstSyncStream * stream)
|
||||||
g_return_if_fail (stream->refcount > 0);
|
g_return_if_fail (stream->refcount > 0);
|
||||||
|
|
||||||
if (g_atomic_int_dec_and_test (&stream->refcount))
|
if (g_atomic_int_dec_and_test (&stream->refcount))
|
||||||
g_slice_free (GstSyncStream, stream);
|
g_free (stream);
|
||||||
}
|
}
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
@ -879,7 +879,7 @@ gst_stream_synchronizer_new_pad (GstStreamSynchronizer * sync)
|
||||||
GstStreamSyncPad *sinkpad, *srcpad;
|
GstStreamSyncPad *sinkpad, *srcpad;
|
||||||
gchar *tmp;
|
gchar *tmp;
|
||||||
|
|
||||||
stream = g_slice_new0 (GstSyncStream);
|
stream = g_new0 (GstSyncStream, 1);
|
||||||
stream->transform = sync;
|
stream->transform = sync;
|
||||||
stream->stream_number = sync->current_stream_number;
|
stream->stream_number = sync->current_stream_number;
|
||||||
g_cond_init (&stream->stream_finish_cond);
|
g_cond_init (&stream->stream_finish_cond);
|
||||||
|
|
|
@ -1215,7 +1215,7 @@ new_decoded_pad_added_cb (GstElement * element, GstPad * pad,
|
||||||
g_object_set_data (G_OBJECT (pad), "uridecodebin.ghostpad", newpad);
|
g_object_set_data (G_OBJECT (pad), "uridecodebin.ghostpad", newpad);
|
||||||
|
|
||||||
/* add event probe to monitor tags */
|
/* add event probe to monitor tags */
|
||||||
stream = g_slice_alloc0 (sizeof (GstURIDecodeBinStream));
|
stream = g_new0 (GstURIDecodeBinStream, 1);
|
||||||
stream->probe_id =
|
stream->probe_id =
|
||||||
gst_pad_add_probe (pad, GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM,
|
gst_pad_add_probe (pad, GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM,
|
||||||
decoded_pad_event_probe, decoder, NULL);
|
decoded_pad_event_probe, decoder, NULL);
|
||||||
|
@ -2140,7 +2140,7 @@ could_not_link:
|
||||||
static void
|
static void
|
||||||
free_stream (gpointer value)
|
free_stream (gpointer value)
|
||||||
{
|
{
|
||||||
g_slice_free (GstURIDecodeBinStream, value);
|
g_free (value);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* remove source and all related elements */
|
/* remove source and all related elements */
|
||||||
|
|
|
@ -675,7 +675,7 @@ add_output_pad (GstURIDecodeBin3 * dec, GstPad * target_pad)
|
||||||
gchar *pad_name;
|
gchar *pad_name;
|
||||||
GstEvent *stream_start;
|
GstEvent *stream_start;
|
||||||
|
|
||||||
output = g_slice_new0 (OutputPad);
|
output = g_new0 (OutputPad, 1);
|
||||||
|
|
||||||
GST_LOG_OBJECT (dec, "Created output %p", output);
|
GST_LOG_OBJECT (dec, "Created output %p", output);
|
||||||
|
|
||||||
|
@ -751,7 +751,7 @@ db_pad_removed_cb (GstElement * element, GstPad * pad, GstURIDecodeBin3 * dec)
|
||||||
/* Remove event probe */
|
/* Remove event probe */
|
||||||
gst_pad_remove_probe (output->target_pad, output->probe_id);
|
gst_pad_remove_probe (output->target_pad, output->probe_id);
|
||||||
|
|
||||||
g_slice_free (OutputPad, output);
|
g_free (output);
|
||||||
|
|
||||||
check_output_group_id (dec);
|
check_output_group_id (dec);
|
||||||
}
|
}
|
||||||
|
@ -1321,7 +1321,7 @@ static void
|
||||||
src_pad_added_cb (GstElement * element, GstPad * pad,
|
src_pad_added_cb (GstElement * element, GstPad * pad,
|
||||||
GstSourceHandler * handler)
|
GstSourceHandler * handler)
|
||||||
{
|
{
|
||||||
GstSourcePad *spad = g_slice_new0 (GstSourcePad);
|
GstSourcePad *spad = g_new0 (GstSourcePad, 1);
|
||||||
GstURIDecodeBin3 *uridecodebin;
|
GstURIDecodeBin3 *uridecodebin;
|
||||||
|
|
||||||
uridecodebin = handler->uridecodebin;
|
uridecodebin = handler->uridecodebin;
|
||||||
|
@ -1401,7 +1401,7 @@ src_pad_removed_cb (GstElement * element, GstPad * pad,
|
||||||
gst_object_unref (spad->stream);
|
gst_object_unref (spad->stream);
|
||||||
|
|
||||||
handler->sourcepads = g_list_remove (handler->sourcepads, spad);
|
handler->sourcepads = g_list_remove (handler->sourcepads, spad);
|
||||||
g_slice_free (GstSourcePad, spad);
|
g_free (spad);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -1427,7 +1427,7 @@ new_source_handler (GstURIDecodeBin3 * uridecodebin, GstPlayItem * item,
|
||||||
{
|
{
|
||||||
GstSourceHandler *handler;
|
GstSourceHandler *handler;
|
||||||
|
|
||||||
handler = g_slice_new0 (GstSourceHandler);
|
handler = g_new0 (GstSourceHandler, 1);
|
||||||
|
|
||||||
handler->uridecodebin = uridecodebin;
|
handler->uridecodebin = uridecodebin;
|
||||||
handler->play_item = item;
|
handler->play_item = item;
|
||||||
|
@ -1653,13 +1653,13 @@ free_source_handler (GstURIDecodeBin3 * uridecodebin,
|
||||||
}
|
}
|
||||||
if (handler->pending_buffering_msg)
|
if (handler->pending_buffering_msg)
|
||||||
gst_message_unref (handler->pending_buffering_msg);
|
gst_message_unref (handler->pending_buffering_msg);
|
||||||
g_slice_free (GstSourceHandler, handler);
|
g_free (handler);
|
||||||
}
|
}
|
||||||
|
|
||||||
static GstSourceItem *
|
static GstSourceItem *
|
||||||
new_source_item (GstURIDecodeBin3 * dec, GstPlayItem * item, gchar * uri)
|
new_source_item (GstURIDecodeBin3 * dec, GstPlayItem * item, gchar * uri)
|
||||||
{
|
{
|
||||||
GstSourceItem *sourceitem = g_slice_new0 (GstSourceItem);
|
GstSourceItem *sourceitem = g_new0 (GstSourceItem, 1);
|
||||||
|
|
||||||
sourceitem->play_item = item;
|
sourceitem->play_item = item;
|
||||||
sourceitem->uri = uri;
|
sourceitem->uri = uri;
|
||||||
|
@ -1674,7 +1674,7 @@ free_source_item (GstURIDecodeBin3 * uridecodebin, GstSourceItem * item)
|
||||||
if (item->handler)
|
if (item->handler)
|
||||||
free_source_handler (uridecodebin, item->handler);
|
free_source_handler (uridecodebin, item->handler);
|
||||||
g_free (item->uri);
|
g_free (item->uri);
|
||||||
g_slice_free (GstSourceItem, item);
|
g_free (item);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -1691,7 +1691,7 @@ source_item_set_uri (GstSourceItem * item, const gchar * uri)
|
||||||
static GstPlayItem *
|
static GstPlayItem *
|
||||||
new_play_item (GstURIDecodeBin3 * dec)
|
new_play_item (GstURIDecodeBin3 * dec)
|
||||||
{
|
{
|
||||||
GstPlayItem *item = g_slice_new0 (GstPlayItem);
|
GstPlayItem *item = g_new0 (GstPlayItem, 1);
|
||||||
|
|
||||||
item->uridecodebin = dec;
|
item->uridecodebin = dec;
|
||||||
item->group_id = GST_GROUP_ID_INVALID;
|
item->group_id = GST_GROUP_ID_INVALID;
|
||||||
|
@ -1708,7 +1708,7 @@ free_play_item (GstURIDecodeBin3 * dec, GstPlayItem * item)
|
||||||
if (item->sub_item)
|
if (item->sub_item)
|
||||||
free_source_item (dec, item->sub_item);
|
free_source_item (dec, item->sub_item);
|
||||||
|
|
||||||
g_slice_free (GstPlayItem, item);
|
g_free (item);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in a new issue