Re: [Qemu-devel] [PATCH] simpletrace: Convert name from mapping record to str

2018-06-27 Thread Stefan Hajnoczi
On Tue, Jun 19, 2018 at 04:45:49PM -0300, Eduardo Habkost wrote: > The rest of the code assumes that idtoname is a (int -> str) > dictionary, so convert the data accordingly. > > This is necessary to make the script work with Python 3 (where > reads from a binary file return 'bytes' objects, not '

[Qemu-devel] [PATCH] simpletrace: Convert name from mapping record to str

2018-06-19 Thread Eduardo Habkost
The rest of the code assumes that idtoname is a (int -> str) dictionary, so convert the data accordingly. This is necessary to make the script work with Python 3 (where reads from a binary file return 'bytes' objects, not 'str'). Fixes the following error: $ python3 ./scripts/simpletrace.py tr