[utils] Register SOCKS protocols in urllib and support SOCKS4A

This commit is contained in:
Yen Chi Hsuan 2016-05-03 15:15:32 +08:00
parent 9e9cd7248d
commit 51fb4995a5
No known key found for this signature in database
GPG key ID: 3FDDD575826C5C30
2 changed files with 13 additions and 1 deletions

View file

@ -64,6 +64,7 @@ from .utils import (
PostProcessingError,
preferredencoding,
prepend_extension,
register_socks_protocols,
render_table,
replace_extension,
SameFileError,
@ -361,6 +362,8 @@ class YoutubeDL(object):
for ph in self.params.get('progress_hooks', []):
self.add_progress_hook(ph)
register_socks_protocols()
def warn_if_short_id(self, argv):
# short YouTube ID starting with dash?
idxs = [