diff options
author | Florin Apostol <florin.apostol@oregan.net> | 2015-07-03 16:10:20 +0100 |
---|---|---|
committer | Thiago Santos <thiagoss@osg.samsung.com> | 2015-07-05 13:25:12 -0300 |
commit | 5151c42085dacfa2c0f4df07d8e27db1036c91e8 (patch) | |
tree | 77940276402b961303e9c804d81457e78735f5fb /ext | |
parent | cf59f3734c6e16f8e30907a3adc8e31505cb82b9 (diff) | |
download | gstreamer-plugins-bad-5151c42085dacfa2c0f4df07d8e27db1036c91e8.tar.gz |
dashdemux: corrected search for audio languages
Corrected the initialisation of mimeType in
gst_mpdparser_get_list_and_nb_of_audio_language: the variable is used
in a loop, so it must be set to NULL at the beginning of each iteration.
https://bugzilla.gnome.org/show_bug.cgi?id=751911
Diffstat (limited to 'ext')
-rw-r--r-- | ext/dash/gstmpdparser.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/ext/dash/gstmpdparser.c b/ext/dash/gstmpdparser.c index 14949e191..366991bf6 100644 --- a/ext/dash/gstmpdparser.c +++ b/ext/dash/gstmpdparser.c @@ -3538,7 +3538,7 @@ gst_mpd_client_setup_streaming (GstMpdClient * client, GST_DEBUG ("0. Current stream %p", stream); - /* retrive representation list */ + /* retrieve representation list */ if (stream->cur_adapt_set != NULL) rep_list = stream->cur_adapt_set->Representations; @@ -4474,11 +4474,12 @@ gst_mpdparser_get_list_and_nb_of_audio_language (GstMpdClient * client, for (list = g_list_first (stream_period->period->AdaptationSets); list; list = g_list_next (list)) { adapt_set = (GstAdaptationSetNode *) list->data; - if (adapt_set) { + if (adapt_set && adapt_set->lang) { gchar *this_lang = adapt_set->lang; GstRepresentationNode *rep; rep = gst_mpdparser_get_lowest_representation (adapt_set->Representations); + mimeType = NULL; if (rep->RepresentationBase) mimeType = rep->RepresentationBase->mimeType; if (!mimeType && adapt_set->RepresentationBase) { @@ -4486,10 +4487,8 @@ gst_mpdparser_get_list_and_nb_of_audio_language (GstMpdClient * client, } if (strncmp_ext (mimeType, this_mimeType) == 0) { - if (this_lang) { - nb_adaptation_set++; - *lang = g_list_append (*lang, this_lang); - } + nb_adaptation_set++; + *lang = g_list_append (*lang, this_lang); } } } |