summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/support/encoded_file.py
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/packages/Python/lldbsuite/support/encoded_file.py')
-rw-r--r--lldb/packages/Python/lldbsuite/support/encoded_file.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/packages/Python/lldbsuite/support/encoded_file.py b/lldb/packages/Python/lldbsuite/support/encoded_file.py
index 2c2fef383f7..5c04cce3b3f 100644
--- a/lldb/packages/Python/lldbsuite/support/encoded_file.py
+++ b/lldb/packages/Python/lldbsuite/support/encoded_file.py
@@ -31,7 +31,7 @@ def _encoded_write(old_write, encoding):
# If we were asked to write a `str` (in Py2) or a `bytes` (in Py3) decode it
# as unicode before attempting to write.
if isinstance(s, six.binary_type):
- s = s.decode(encoding)
+ s = s.decode(encoding, "replace")
return old_write(s)
return impl
OpenPOWER on IntegriCloud