aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2015-08-02 01:13:59 +0600
committerSergey M․ <dstftw@gmail.com>2015-08-02 01:13:59 +0600
commite5e8d20a3a65832c74b002f247866fcbb92e9246 (patch)
treeef6d081e7820a3683a0ca23e6578d4f79da71d42
parenta107193e4b7a3d5414dd7422263c34ac0e309ec4 (diff)
[extractor/generic] Improve generic SMIL detection
-rw-r--r--youtube_dl/extractor/generic.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/youtube_dl/extractor/generic.py b/youtube_dl/extractor/generic.py
index 8cef61c3c..6900ed96f 100644
--- a/youtube_dl/extractor/generic.py
+++ b/youtube_dl/extractor/generic.py
@@ -1110,11 +1110,13 @@ class GenericIE(InfoExtractor):
self.report_extraction(video_id)
- # Is it an RSS feed?
+ # Is it an RSS feed or a SMIL file?
try:
doc = parse_xml(webpage)
if doc.tag == 'rss':
return self._extract_rss(url, video_id, doc)
+ elif re.match(r'^(?:{[^}]+})?smil$', doc.tag):
+ return self._parse_smil(doc, url, video_id)
except compat_xml_parse_error:
pass