]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - lib/fdtdec.c
fdtdec: Fix possible infinite loop in fdtdec_get_pci_vendev()
[karo-tx-uboot.git] / lib / fdtdec.c
index b65e1e6185550e4651ebce5ecb46d50cecccf791..81b54f88e88722eab0458d83fce8684072baaffc 100644 (file)
@@ -207,9 +207,8 @@ int fdtdec_get_pci_vendev(const void *blob, int node, u16 *vendor, u16 *device)
 
                                return 0;
                        }
-               } else {
-                       list += (len + 1);
                }
+               list += (len + 1);
        }
 
        return -ENOENT;