]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - lib/libfdt/fdt_ro.c
libfdt: fix error code of fdt_get_string_index()
[karo-tx-uboot.git] / lib / libfdt / fdt_ro.c
index 44fc0aa900d2556996ab5f9ef7c87f12fca517ce..38bfcbdcd53d2b4d150b429e6fe38ddbfb1a91a4 100644 (file)
@@ -577,7 +577,7 @@ int fdt_get_string_index(const void *fdt, int node, const char *property,
                index--;
        }
 
-       return FDT_ERR_NOTFOUND;
+       return -FDT_ERR_NOTFOUND;
 }
 
 int fdt_get_string(const void *fdt, int node, const char *property,