Minor patch

This commit is contained in:
Miroslav Stampar 2013-04-06 01:48:23 +02:00
parent a75d3ed0b8
commit 50ac3aab7a
2 changed files with 2 additions and 2 deletions

View File

@ -777,7 +777,7 @@ def dataToStdout(data, forceOutput=False, bold=False, content_type=None, status=
if kb.get("multiThreadMode"):
logging._acquireLock()
if isinstance(data, basestring):
if isinstance(data, unicode):
message = stdoutencode(data)
else:
message = data

View File

@ -141,7 +141,7 @@ def stdoutencode(data):
try:
# Reference: http://bugs.python.org/issue1602
if IS_WIN:
output = data.encode('ascii', "replace")
output = data.encode("ascii", "replace")
if output != data:
warnMsg = "cannot properly display Unicode characters "