diff options
author | Chris Packham <chris.packham@alliedtelesis.co.nz> | 2020-11-27 13:07:08 +1300 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-11-29 23:39:41 +0100 |
commit | 54d68799b73e755923def1306b4da607ad45bd60 (patch) | |
tree | e5a96954da903dbc82b3be63b932b62015ad3f33 /ubifs-utils/mkfs.ubifs/key.h | |
parent | 5a6e813a6ba48c81889208bdbeff92b13958dd2d (diff) |
libmtd: avoid divide by zero
The concept of erase blocks doesn't apply to mtd-ram devices. Such
devices set MTD_NO_ERASE to indicate this and some report 0 for the
erase block size. Avoid a divide by zero when calculating the erase
block count for such devices.
Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Acked-by: Richard Weinberger <richard@nod.at>
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'ubifs-utils/mkfs.ubifs/key.h')
0 files changed, 0 insertions, 0 deletions