Browse Source

[utils] Add rationale for register_socks_protocols

totalwebcasting
Yen Chi Hsuan 9 years ago
parent
commit
d5ae6bb501
No known key found for this signature in database GPG Key ID: 3FDDD575826C5C30
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      youtube_dl/utils.py

+ 2
- 0
youtube_dl/utils.py View File

@ -63,6 +63,8 @@ from .socks import (
def register_socks_protocols():
# "Register" SOCKS protocols
# In Python < 2.6.5, urlsplit() suffers from bug https://bugs.python.org/issue7904
# URLs with protocols not in urlparse.uses_netloc are not handled correctly
for scheme in ('socks', 'socks4', 'socks4a', 'socks5'):
if scheme not in compat_urlparse.uses_netloc:
compat_urlparse.uses_netloc.append(scheme)


Loading…
Cancel
Save