Merge 2f6051480d
into d65d89183f
This commit is contained in:
commit
8730869dfa
|
@ -17,7 +17,7 @@ class XVideosIE(InfoExtractor):
|
|||
_VALID_URL = r'''(?x)
|
||||
https?://
|
||||
(?:
|
||||
(?:[^/]+\.)?xvideos2?\.com/video|
|
||||
(?:[^/]+\.)?xvideos[23]?\.com/video|
|
||||
(?:www\.)?xvideos\.es/video|
|
||||
flashservice\.xvideos\.com/embedframe/|
|
||||
static-hw\.xvideos\.com/swf/xv-player\.swf\?.*?\bid_video=
|
||||
|
@ -76,13 +76,29 @@ class XVideosIE(InfoExtractor):
|
|||
}, {
|
||||
'url': 'https://de.xvideos.com/video4588838/biker_takes_his_girl',
|
||||
'only_matching': True
|
||||
}, {
|
||||
'url': 'https://www.xvideos2.com/video4588838/biker_takes_his_girl',
|
||||
'only_matching': True
|
||||
}, {
|
||||
'url': 'https://www.xvideos3.com/video4588838/biker_takes_his_girl',
|
||||
'only_matching': True
|
||||
}]
|
||||
|
||||
HOSTS = ['xvideos', 'xvideos2', 'xvideos3']
|
||||
|
||||
def _real_extract(self, url):
|
||||
video_id = self._match_id(url)
|
||||
|
||||
webpage = self._download_webpage(
|
||||
'https://www.xvideos.com/video%s/' % video_id, video_id)
|
||||
self.report_download_webpage(video_id)
|
||||
for i, host in enumerate(self.HOSTS):
|
||||
webpage = self._download_webpage(
|
||||
'https://www.' + host + '.com/video%s/' % video_id, video_id,
|
||||
note=False, fatal=host == self.HOSTS[-1], errnote=host == self.HOSTS[-1])
|
||||
if webpage:
|
||||
temp_host = self.HOSTS[0]
|
||||
self.HOSTS[0] = host
|
||||
self.HOSTS[i] = temp_host
|
||||
break
|
||||
|
||||
mobj = re.search(r'<h1 class="inlineError">(.+?)</h1>', webpage)
|
||||
if mobj:
|
||||
|
|
Loading…
Reference in New Issue