From: Philipp Hagemeister Date: Fri, 15 Nov 2013 00:45:34 +0000 (+0100) Subject: [youtube] Fix protocol-independent URLs (Fixes #1768) X-Git-Url: https://git.cielonegro.org/gitweb.cgi?a=commitdiff_plain;h=9f9be844fcc5155ab3e832c8428c8f016bea819b;p=youtube-dl.git [youtube] Fix protocol-independent URLs (Fixes #1768) --- diff --git a/youtube_dl/extractor/youtube.py b/youtube_dl/extractor/youtube.py index c992cba97..ed82e4fc0 100644 --- a/youtube_dl/extractor/youtube.py +++ b/youtube_dl/extractor/youtube.py @@ -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: