Skip to content

Commit

Permalink
Attempt to stop the unicode hemorrhaging.
Browse files Browse the repository at this point in the history
  • Loading branch information
ralphbean committed Sep 9, 2012
1 parent db7b4db commit 130195c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ansi2html/converter.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,8 @@ def _print(output_unicode):
if hasattr(sys.stdout, 'buffer'):
output_bytes = output_unicode.encode(opts.output_encoding)
sys.stdout.buffer.write(output_bytes)
elif not six.PY3:
print(output_unicode.encode(opts.output_encoding))
else:
print(output_unicode)

Expand Down

0 comments on commit 130195c

Please sign in to comment.