diff --git a/share/qtcreator/debugger/dumper.py b/share/qtcreator/debugger/dumper.py index d24d649f556..b2ca3c00cab 100644 --- a/share/qtcreator/debugger/dumper.py +++ b/share/qtcreator/debugger/dumper.py @@ -24,6 +24,7 @@ ############################################################################ import os +import codecs import copy import collections import struct @@ -436,7 +437,7 @@ class DumperBase: elif self.currentValue.encoding == 'utf8': value = self.hexdecode(value) elif self.currentValue.encoding == 'utf16': - b = bytes.fromhex(value) + b = bytes(bytearray.fromhex(value)) value = codecs.decode(b, 'utf-16') self.put('"%s"' % value) if self.currentValue.elided: