]> git.baikalelectronics.ru Git - uboot.git/commit
dtoc: Decode val if it's a byte string
authorGeorge McCollister <george.mccollister@gmail.com>
Thu, 30 Mar 2017 14:44:25 +0000 (09:44 -0500)
committerSimon Glass <sjg@chromium.org>
Thu, 13 Apr 2017 17:43:49 +0000 (11:43 -0600)
commite7ced7b6bcd4f4d028ff4a81d38d5b9931c2afbc
treef50439a666cc62aad59bf49b611a1f43db75103d
parentf0a04d523c2f12a89aca6d51013933e022024008
dtoc: Decode val if it's a byte string

With Python 3.5.2 encode will throw an exception if val is a byte array.
Decode it to a string first. This assumes it's utf-8, if it's not valid
utf-8 it will throw an exception.

Signed-off-by: George McCollister <george.mccollister@gmail.com>
Acked-by: Simon Glass <sjg@chromium.org>
tools/dtoc/fdt_util.py