X-Git-Url: http://git.openwrt.org/?p=project%2Ffstools.git;a=blobdiff_plain;f=libfstools%2Fubi.c;h=3051720f65d8df6fc58848ff2422eae5d3c88d17;hp=42f76ca7a29a794cc9a2d968095f41c6b3e0f74b;hb=efacbcb4973161c12cc9630d243669845db41a17;hpb=f809e352ca1556c4ffc5f40261799db86062d49e diff --git a/libfstools/ubi.c b/libfstools/ubi.c index 42f76ca..3051720 100644 --- a/libfstools/ubi.c +++ b/libfstools/ubi.c @@ -138,7 +138,7 @@ static int ubi_volume_match(struct volume *v, char *name, int ubi_num, int volid volname = read_string_from_file(voldir, "name"); - if (strncmp(name, volname, strlen(volname))) + if (strncmp(name, volname, strlen(volname) + 1)) return -1; p = calloc(1, sizeof(struct ubi_priv));