diff options
author | Christopher Rosell <chrippa@tanuki.se> | 2012-09-26 14:28:09 +0200 |
---|---|---|
committer | Christopher Rosell <chrippa@tanuki.se> | 2012-09-26 14:28:09 +0200 |
commit | b69a3f96455f3333bc70b67f828cda784fc4ac99 (patch) | |
tree | 41b38d25f3573cbffd3afbd5ec675f162034c0ca /src/livestreamer/compat.py | |
parent | 0a981dc25b52f234a459d613c3084af3abc81763 (diff) |
Fix file check on Python 3.
Diffstat (limited to 'src/livestreamer/compat.py')
-rw-r--r-- | src/livestreamer/compat.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/livestreamer/compat.py b/src/livestreamer/compat.py index d91021f..f32fe47 100644 --- a/src/livestreamer/compat.py +++ b/src/livestreamer/compat.py @@ -10,6 +10,7 @@ if is_py2: stdout = sys.stdout _str = str str = unicode + file = file def bytes(b, enc="ascii"): return _str(b) @@ -19,6 +20,7 @@ elif is_py3: input = input stdout = sys.stdout.buffer str = str + from io import IOBase as file try: from urllib.parse import urlparse, urljoin, quote, unquote, parse_qs |