[PATCH 1/2] mtdpart: Avoid divide-by-zero on out-of-reach path
Jörn Engel
joern at logfs.org
Wed Jun 18 13:40:34 EDT 2008
On Wed, 18 June 2008 11:19:07 +0900, Atsushi Nemoto wrote:
>
> The decrement is there because when the first loop stoped 'i' points
> the second region in the partition.
Finally even I understand that code. Thank you for your patience.
> Putting 'goto somewhere' or 'slave->mtd.erasesize = master->erasesize'
> in the above 'if' block can be an alternative fix.
That seems a better idea.
Jörn
--
A defeated army first battles and then seeks victory.
-- Sun Tzu
More information about the linux-mtd
mailing list