diff options
author | Sergey M․ <dstftw@gmail.com> | 2015-08-16 19:53:14 +0600 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2015-08-16 19:53:14 +0600 |
commit | 7fc18d930917ad407c78bb9b0465dc4fae2fb335 (patch) | |
tree | a7b613e1f91b00b571ac3a2719c7443ec9bebb09 /youtube_dl/extractor | |
parent | 974f1a385a452b1c86d6f3ff16035b30baaeeb64 (diff) |
[screenwavemedia] Fix extraction (Closes #6575)
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/screenwavemedia.py | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/youtube_dl/extractor/screenwavemedia.py b/youtube_dl/extractor/screenwavemedia.py index 3bc84989e..78b068be2 100644 --- a/youtube_dl/extractor/screenwavemedia.py +++ b/youtube_dl/extractor/screenwavemedia.py @@ -1,6 +1,8 @@ # encoding: utf-8 from __future__ import unicode_literals +import re + from .common import InfoExtractor from ..utils import ( int_or_none, @@ -35,15 +37,18 @@ class ScreenwaveMediaIE(InfoExtractor): sources = self._parse_json( js_to_json( - self._search_regex( - r"sources\s*:\s*(\[[^\]]+?\])", playerconfig, - 'sources', - ).replace( - "' + thisObj.options.videoserver + '", - videoserver - ).replace( - "' + playerVidId + '", - video_id + re.sub( + r'(?s)/\*.*?\*/', '', + self._search_regex( + r"sources\s*:\s*(\[[^\]]+?\])", playerconfig, + 'sources', + ).replace( + "' + thisObj.options.videoserver + '", + videoserver + ).replace( + "' + playerVidId + '", + video_id + ) ) ), video_id |