ext2: avoid possible overflow when calculating malloc size.

This is inspired on r308064 for case of reloading UFS.

MFC after:	1 week
This commit is contained in:
Pedro F. Giffuni 2016-11-26 02:06:33 +00:00
parent 79b4dcad2b
commit bb9535bbc7

View File

@ -537,7 +537,8 @@ ext2_mountfs(struct vnode *devvp, struct mount *mp)
struct csum *sump;
int error;
int ronly;
int i, size;
int i;
u_long size;
int32_t *lp;
int32_t e2fs_maxcontig;