replaygain: fix taglist leak in rganalysis

And add some FIXMEs.
This commit is contained in:
Tim-Philipp Müller 2013-09-02 23:00:29 +01:00
parent cc4f985332
commit 966f848edb

View file

@ -532,6 +532,7 @@ gst_rg_analysis_stop (GstBaseTransform * base)
return TRUE; return TRUE;
} }
/* FIXME: handle global vs. stream-tags? */
static void static void
gst_rg_analysis_handle_tags (GstRgAnalysis * filter, gst_rg_analysis_handle_tags (GstRgAnalysis * filter,
const GstTagList * tag_list) const GstTagList * tag_list)
@ -632,9 +633,10 @@ gst_rg_analysis_handle_eos (GstRgAnalysis * filter)
GST_LOG_OBJECT (filter, "posting tag list with results"); GST_LOG_OBJECT (filter, "posting tag list with results");
gst_tag_list_add (tag_list, GST_TAG_MERGE_APPEND, gst_tag_list_add (tag_list, GST_TAG_MERGE_APPEND,
GST_TAG_REFERENCE_LEVEL, filter->reference_level, NULL); GST_TAG_REFERENCE_LEVEL, filter->reference_level, NULL);
/* This steals our reference to the list: */ /* This takes ownership of our reference to the list */
gst_pad_push_event (GST_BASE_TRANSFORM_SRC_PAD (GST_BASE_TRANSFORM gst_pad_push_event (GST_BASE_TRANSFORM_SRC_PAD (filter),
(filter)), gst_event_new_tag (gst_tag_list_ref (tag_list))); gst_event_new_tag (tag_list));
tag_list = NULL;
} }
} }
@ -653,6 +655,7 @@ gst_rg_analysis_handle_eos (GstRgAnalysis * filter)
g_object_notify (G_OBJECT (filter), "num-tracks"); g_object_notify (G_OBJECT (filter), "num-tracks");
} }
/* FIXME: return tag list (lists?) based on input tags.. */
static gboolean static gboolean
gst_rg_analysis_track_result (GstRgAnalysis * filter, GstTagList ** tag_list) gst_rg_analysis_track_result (GstRgAnalysis * filter, GstTagList ** tag_list)
{ {