aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2014-09-16 22:53:48 +0200
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2014-09-16 22:53:48 +0200
commita04aa7a9e692b174f4b03ddf6918c2d0a20ff7fc (patch)
tree9d90cd5968e5cc74a9f9df521925c7609fce3740
parent64892c0b79b401ab487c8facb5a646011873194c (diff)
downloadyoutube-dl-a04aa7a9e692b174f4b03ddf6918c2d0a20ff7fc.tar.xz
[generic] The url in the <meta redirect> doesn't need to be enclosed in single quotes (fixes #3770)
See the examples in https://en.wikipedia.org/wiki/Meta_refresh or the shortened urls from https://t.co/.
-rw-r--r--youtube_dl/extractor/generic.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/youtube_dl/extractor/generic.py b/youtube_dl/extractor/generic.py
index 2bfa20606..40eeaad16 100644
--- a/youtube_dl/extractor/generic.py
+++ b/youtube_dl/extractor/generic.py
@@ -877,7 +877,7 @@ class GenericIE(InfoExtractor):
if not found:
found = re.search(
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)
if found:
new_url = found.group(1)