From 0541c44addfffcdeaae75a57ffb7ac8a6800e4db Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Thu, 3 Sep 2009 14:13:43 +0300 Subject: [PATCH] speexenc: small taglist handling cleanup Don't eventualy leak the list and instead assert (like in other elements). --- ext/speex/gstspeexenc.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/speex/gstspeexenc.c b/ext/speex/gstspeexenc.c index d873ed0..17e1703 100644 --- a/ext/speex/gstspeexenc.c +++ b/ext/speex/gstspeexenc.c @@ -852,12 +852,14 @@ gst_speex_enc_sinkevent (GstPad * pad, GstEvent * event) break; case GST_EVENT_TAG: { - GstTagList *list; - - gst_event_parse_tag (event, &list); if (enc->tags) { + GstTagList *list; + + gst_event_parse_tag (event, &list); gst_tag_list_insert (enc->tags, list, gst_tag_setter_get_tag_merge_mode (GST_TAG_SETTER (enc))); + } else { + g_assert_not_reached (); } res = gst_pad_event_default (pad, event); break; -- 2.7.4