diff options
author | Philipp Hagemeister <phihag@phihag.de> | 2012-11-26 04:23:20 +0100 |
---|---|---|
committer | Philipp Hagemeister <phihag@phihag.de> | 2012-11-26 04:23:20 +0100 |
commit | 92b91c18780938283c505f5662c458e049bf3567 (patch) | |
tree | 8d91ceb8131b4698583704ca62ff77ae35a61779 /youtube_dl/FileDownloader.py | |
parent | 7ec1a206eaedcb35c16ba54289d3c7f92baa59ce (diff) |
Use character instead of byte strings
Diffstat (limited to 'youtube_dl/FileDownloader.py')
-rw-r--r-- | youtube_dl/FileDownloader.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/youtube_dl/FileDownloader.py b/youtube_dl/FileDownloader.py index ff6963262..37a842cdd 100644 --- a/youtube_dl/FileDownloader.py +++ b/youtube_dl/FileDownloader.py @@ -180,7 +180,8 @@ class FileDownloader(object): def to_stderr(self, message): """Print message to stderr.""" - print >>sys.stderr, message.encode(preferredencoding()) + assert type(message) == type(u'') + sys.stderr.write((message + u'\n').encode(preferredencoding())) def to_cons_title(self, message): """Set console/terminal window title to message.""" |