mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-19 23:06:49 +00:00
dashdemux: gst_mpdparser_get_xml_prop_duration sets default value in case of parsing errors
The gst_mpdparser_get_xml_prop_duration function will set the property_value to the default_value in case the parsing fails. https://bugzilla.gnome.org/show_bug.cgi?id=752426
This commit is contained in:
parent
4be7e0377b
commit
a7751aa967
1 changed files with 1 additions and 5 deletions
|
@ -788,6 +788,7 @@ gst_mpdparser_get_xml_prop_duration (xmlNode * a_node,
|
|||
gboolean have_ms = FALSE;
|
||||
gboolean exists = FALSE;
|
||||
|
||||
*property_value = default_value;
|
||||
prop_string = xmlGetProp (a_node, (const xmlChar *) property_name);
|
||||
if (prop_string) {
|
||||
len = xmlStrlen (prop_string);
|
||||
|
@ -910,9 +911,6 @@ gst_mpdparser_get_xml_prop_duration (xmlNode * a_node,
|
|||
GST_LOG (" - %s: %" G_GINT64_FORMAT, property_name, *property_value);
|
||||
}
|
||||
|
||||
if (!exists) {
|
||||
*property_value = default_value;
|
||||
}
|
||||
return exists;
|
||||
|
||||
error:
|
||||
|
@ -1648,8 +1646,6 @@ gst_mpdparser_parse_period_node (GList ** list, xmlNode * a_node)
|
|||
new_period = g_slice_new0 (GstPeriodNode);
|
||||
*list = g_list_append (*list, new_period);
|
||||
|
||||
new_period->start = GST_CLOCK_TIME_NONE;
|
||||
|
||||
GST_LOG ("attributes of Period node:");
|
||||
gst_mpdparser_get_xml_prop_string (a_node, "id", &new_period->id);
|
||||
gst_mpdparser_get_xml_prop_duration (a_node, "start", -1, &new_period->start);
|
||||
|
|
Loading…
Reference in a new issue