]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[youtube] Fix protocol-independent URLs (Fixes #1768)
authorPhilipp Hagemeister <phihag@phihag.de>
Fri, 15 Nov 2013 00:45:34 +0000 (01:45 +0100)
committerPhilipp Hagemeister <phihag@phihag.de>
Fri, 15 Nov 2013 00:45:39 +0000 (01:45 +0100)
youtube_dl/extractor/youtube.py

index c992cba978441081a50e5f134a4a694c83a6685c..ed82e4fc02878b1cac9019ca1439ac7d31ca8cd7 100644 (file)
@@ -1019,6 +1019,8 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
         """Turn the encrypted s field into a working signature"""
 
         if player_url is not None:
+            if player_url.startswith(u'//'):
+                player_url = u'https:' + player_url
             try:
                 player_id = (player_url, len(s))
                 if player_id not in self._player_cache: