1
0
mirror of https://github.com/ARM-software/devlib.git synced 2025-01-31 02:00:45 +00:00

utils/rendering: Fix Python 3 compatibility

Add missing encoding of string when writing out fps data.
This commit is contained in:
Marc Bonnici 2018-09-04 11:41:32 +01:00 committed by setrofim
parent 61208ce2e0
commit 996ee82f09

View File

@ -194,7 +194,11 @@ class GfxinfoFrameCollector(FrameCollector):
def collect_frames(self, wfh):
cmd = 'dumpsys gfxinfo {} framestats'
wfh.write(self.target.execute(cmd.format(self.package)))
result = self.target.execute(cmd.format(self.package))
if sys.version_info[0] == 3:
wfh.write(result.encode('utf-8'))
else:
wfh.write(result)
def clear(self):
pass