pygrub: encode / decode string in Python 3
authorWei Liu <wei.liu2@citrix.com>
Mon, 1 Apr 2019 10:32:37 +0000 (11:32 +0100)
committerWei Liu <wei.liu2@citrix.com>
Tue, 2 Apr 2019 08:50:41 +0000 (09:50 +0100)
commitff915c8cacc264ae1380d51fea07267b8308d7ba
tree7b8a7cb54ff6adb74ac0fc4f9d40f5641d92c243
parent767ba397d34848c7e0c4e9cdfc5efa4e0cb61442
pygrub: encode / decode string in Python 3

String is unicode in 3 but bytes in 2. We need to call encode / decode
function when using Python 3.

Reported-by: M A Young <m.a.young@durham.ac.uk>
Signed-off-by: Wei Liu <wei.liu2@citrix.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
tools/pygrub/src/pygrub