diff --git a/lldb/test/API/lldbtest.py b/lldb/test/API/lldbtest.py --- a/lldb/test/API/lldbtest.py +++ b/lldb/test/API/lldbtest.py @@ -120,8 +120,8 @@ if sys.version_info.major == 2: # In Python 2, string objects can contain Unicode characters. - out = out.decode('utf-8') - err = err.decode('utf-8') + out = out.decode('utf-8', 'replace') + err = err.decode('utf-8', 'replace') output = """Script:\n--\n%s\n--\nExit Code: %d\n""" % ( ' '.join(cmd), exitCode)