hls: m3u8: remove impossible condition

After the check in line 1,111,  media->uri can't be NULL. So the two checks
for GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS are the same, removing the redundant
one which goes to cc_unsupported.

CID 1364752
This commit is contained in:
Luis de Bethencourt 2016-08-04 11:08:30 +01:00
parent 35c82fee32
commit 2ed4135237

View File

@ -1114,11 +1114,8 @@ gst_m3u8_parse_media (gchar * desc, const gchar * base_uri)
if (media->group_id == NULL || media->name == NULL) if (media->group_id == NULL || media->name == NULL)
goto required_attributes_missing; goto required_attributes_missing;
if (mtype == GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS && media->uri != NULL)
goto uri_with_cc;
if (mtype == GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS) if (mtype == GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS)
goto cc_unsupported; goto uri_with_cc;
GST_DEBUG ("media: %s, group '%s', name '%s', uri '%s', %s %s %s, lang=%s", GST_DEBUG ("media: %s, group '%s', name '%s', uri '%s', %s %s %s, lang=%s",
GST_HLS_MEDIA_TYPE_NAME (media->mtype), media->group_id, media->name, GST_HLS_MEDIA_TYPE_NAME (media->mtype), media->group_id, media->name,
@ -1128,11 +1125,6 @@ gst_m3u8_parse_media (gchar * desc, const gchar * base_uri)
return media; return media;
cc_unsupported:
{
GST_FIXME ("closed captions EXT-X-MEDIA are not yet supported");
goto out_error;
}
uri_with_cc: uri_with_cc:
{ {
GST_WARNING ("closed captions EXT-X-MEDIA should not have URI specified"); GST_WARNING ("closed captions EXT-X-MEDIA should not have URI specified");