[package] iwinfo: fix logic flaw in mtd partition check
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@30678 3c298f89-4303-0410-b956-a3cf2f4a3e73master
parent
539e529fb5
commit
39923b50f8
|
@ -165,7 +165,7 @@ int iwinfo_hardware_id_from_mtd(struct iwinfo_hardware_id *id)
|
||||||
while (fgets(buf, sizeof(buf), mtd) > 0)
|
while (fgets(buf, sizeof(buf), mtd) > 0)
|
||||||
{
|
{
|
||||||
if (fscanf(mtd, "mtd%d: %*x %x %127s", &off, &len, buf) < 3 ||
|
if (fscanf(mtd, "mtd%d: %*x %x %127s", &off, &len, buf) < 3 ||
|
||||||
strcmp(buf, "\"boardconfig\"") || strcmp(buf, "\"EEPROM\""))
|
(strcmp(buf, "\"boardconfig\"") && strcmp(buf, "\"EEPROM\"")))
|
||||||
{
|
{
|
||||||
off = -1;
|
off = -1;
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Reference in New Issue