mtd/at25ee.c: Fix write check condition

Fix writing till the very last byte of the memory

Signed-off-by: Antoine Juckler <6445757+ajuckler@users.noreply.github.com>
This commit is contained in:
Antoine Juckler 2025-11-11 13:45:09 +09:00 • committed by Alan C. Assis
parent 23de88e70e
commit d996c2e758

View file

@ -667,7 +667,7 @@ static ssize_t at25ee_write(FAR struct mtd_dev_s *dev, off_t offset,
/* Forbid writes past the end of the device */
if (nbytes + offset >= priv->size)
if (nbytes + offset > priv->size)
{
return 0;
}