[Crosstoolchain-logs] [device-tree-compiler] 19/22: libfdt: fix fdt_stringlist_count()

Hector Oron zumbi at moszumanska.debian.org
Thu Dec 8 17:07:27 UTC 2016


This is an automated email from the git hooks/post-receive script.

zumbi pushed a commit to branch upstream/latest
in repository device-tree-compiler.

commit e28eff5b787adb3f461d1653598818b2f1f25a73
Author: Masahiro Yamada <yamada.masahiro at socionext.com>
Date:   Mon Oct 17 15:08:23 2016 +0900

    libfdt: fix fdt_stringlist_count()
    
    If fdt_getprop() fails, negative error code should be returned.
    
    Signed-off-by: Masahiro Yamada <yamada.masahiro at socionext.com>
    Signed-off-by: David Gibson <david at gibson.dropbear.id.au>
---
 libfdt/fdt_ro.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libfdt/fdt_ro.c b/libfdt/fdt_ro.c
index 0459098..db8d10f 100644
--- a/libfdt/fdt_ro.c
+++ b/libfdt/fdt_ro.c
@@ -571,7 +571,7 @@ int fdt_stringlist_count(const void *fdt, int nodeoffset, const char *property)
 
 	list = fdt_getprop(fdt, nodeoffset, property, &length);
 	if (!list)
-		return -length;
+		return length;
 
 	end = list + length;
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/crosstoolchain/device-tree-compiler.git



More information about the Crosstoolchain-logs mailing list