summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/binaryview.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/python/binaryview.py b/python/binaryview.py
index 6b6adffc..1cf802a2 100644
--- a/python/binaryview.py
+++ b/python/binaryview.py
@@ -5382,7 +5382,7 @@ class BinaryView(object):
offset = ctypes.c_ulonglong()
errors = ctypes.c_char_p()
if not core.BNParseExpression(self.handle, expression, offset, here, errors):
- error_str = errors.value
+ error_str = errors.value.decode("utf-8")
core.BNFreeString(ctypes.cast(errors, ctypes.POINTER(ctypes.c_byte)))
raise ValueError(error_str)
return offset.value