[PATCH] mtd-utils: lib: mtd_read: Take the buffer offset into account when reading

Marcus Prebble marcus.prebble at axis.com
Tue Oct 6 05:13:23 PDT 2015


Hi mtd-list,

Assuming the read() call does not return zero and the result is less
than len, the current implementation will overwrite the data already
read in buf which doesn't seem correct.

Suggested patch attached (git format-patch)

-Marcus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-mtd_read-Take-the-buffer-offset-into-account-when-re.patch
Type: text/x-patch
Size: 944 bytes
Desc: 0001-mtd_read-Take-the-buffer-offset-into-account-when-re.patch
URL: <http://lists.infradead.org/pipermail/linux-mtd/attachments/20151006/69610e1c/attachment.bin>


More information about the linux-mtd mailing list