mirror of
https://codeberg.org/polarisfm/youtube-dl
synced 2024-11-26 10:24:33 +01:00
Use alternative imports for Python 2.4 (Closes #138)
This commit is contained in:
parent
134cff47ab
commit
0a3c8b6291
@ -12,9 +12,7 @@
|
||||
from __future__ import with_statement
|
||||
import contextlib
|
||||
import cookielib
|
||||
import ctypes
|
||||
import datetime
|
||||
import email.utils
|
||||
import gzip
|
||||
import htmlentitydefs
|
||||
import httplib
|
||||
@ -34,6 +32,13 @@ import urllib2
|
||||
import warnings
|
||||
import zlib
|
||||
|
||||
if os.name == 'nt':
|
||||
import ctypes
|
||||
|
||||
try:
|
||||
import email.utils
|
||||
except ImportError: # Python 2.4
|
||||
import email.Utils
|
||||
try:
|
||||
import cStringIO as StringIO
|
||||
except ImportError:
|
||||
|
Loading…
Reference in New Issue
Block a user