Commit c2056e1e1ddcca8d43e89543e1795e4457f5d1e9
Committed by
David Woodhouse
1 parent
6c24e4161e
Exists in
master
and in
7 other branches
[JFFS2] Fix return value check for mtd->point() in check_node_data()
If we ask it to map 'len' bytes of the device, don't compare against some other number and whine that it's different. That's a little silly. Signed-off-by: Alexey Korolev <akorolev@infradead.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff
fs/jffs2/readinode.c
... | ... | @@ -64,7 +64,7 @@ |
64 | 64 | * adding and jffs2_flash_read_end() interface. */ |
65 | 65 | if (c->mtd->point) { |
66 | 66 | err = c->mtd->point(c->mtd, ofs, len, &retlen, &buffer); |
67 | - if (!err && retlen < tn->csize) { | |
67 | + if (!err && retlen < len) { | |
68 | 68 | JFFS2_WARNING("MTD point returned len too short: %zu instead of %u.\n", retlen, tn->csize); |
69 | 69 | c->mtd->unpoint(c->mtd, buffer, ofs, retlen); |
70 | 70 | } else if (err) |