This commit is contained in:
Kovid Goyal 2012-11-30 23:22:21 +05:30
parent 5b3dfa2595
commit d375406b42

View File

@ -182,7 +182,7 @@ def debug(ioreg_to_tmp=False, buf=None, plugins=None,
out(ioreg) out(ioreg)
if hasattr(buf, 'getvalue'): if hasattr(buf, 'getvalue'):
return buf.getvalue().decode('utf-8') return buf.getvalue().decode('utf-8', 'replace')
finally: finally:
sys.stdout = oldo sys.stdout = oldo
sys.stderr = olde sys.stderr = olde