1
0
mirror of https://github.com/l1ving/youtube-dl synced 2024-11-25 08:52:53 +08:00

[generic] Fix redirect

This commit is contained in:
Sergey M․ 2014-05-16 20:32:53 +07:00
parent beee53de06
commit a5a45015ba

View File

@ -672,7 +672,7 @@ class GenericIE(InfoExtractor):
# HTML5 video # HTML5 video
found = re.findall(r'(?s)<video[^<]*(?:>.*?<source.*?)? src="([^"]+)"', webpage) found = re.findall(r'(?s)<video[^<]*(?:>.*?<source.*?)? src="([^"]+)"', webpage)
if not found: if not found:
found = re.findall( found = re.search(
r'(?i)<meta\s+(?=(?:[a-z-]+="[^"]+"\s+)*http-equiv="refresh")' r'(?i)<meta\s+(?=(?:[a-z-]+="[^"]+"\s+)*http-equiv="refresh")'
r'(?:[a-z-]+="[^"]+"\s+)*?content="[0-9]{,2};url=\'([^\']+)\'"', r'(?:[a-z-]+="[^"]+"\s+)*?content="[0-9]{,2};url=\'([^\']+)\'"',
webpage) webpage)