From: Lumir Balhar <lbalhar@xxxxxxxxxx> In Python 2, an empty list is always higher than zero but in Python 3 these types cannot be compared. Signed-off-by: Lumir Balhar <lbalhar@xxxxxxxxxx> --- pylibfdt/libfdt.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pylibfdt/libfdt.i b/pylibfdt/libfdt.i index 88d443d..9c0dcdc 100644 --- a/pylibfdt/libfdt.i +++ b/pylibfdt/libfdt.i @@ -124,7 +124,7 @@ def check_err(val, quiet=()): Raises FdtException if val < 0 """ - if val < 0: + if isinstance(val, int) and val < 0: if -val not in quiet: raise FdtException(val) return val -- 2.17.1 -- To unsubscribe from this list: send the line "unsubscribe devicetree-compiler" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html