The text of a printf() states that we're printing OOB area, but the
corresponding argument passes writesize. That probably wasn't the intent.
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
// Check, if length fits into device
if (((imglen / pagelen) * meminfo.writesize) > (meminfo.size - mtdoffset)) {
fprintf(stderr, "Image %d bytes, NAND page %d bytes, OOB area %u bytes, device size %u bytes\n",
- imglen, pagelen, meminfo.writesize, meminfo.size);
+ imglen, pagelen, meminfo.oobsize, meminfo.size);
perror("Input file does not fit into device");
goto closeall;
}