Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b434babf authored by Fabian Frederick's avatar Fabian Frederick Committed by Jaegeuk Kim
Browse files

f2fs: replace count*size kzalloc by kcalloc



kcalloc manages count*sizeof overflow.

Cc: Jaegeuk Kim <jaegeuk.kim@samsung.com>
Cc: linux-f2fs-devel@lists.sourceforge.net
Signed-off-by: default avatarFabian Frederick <fabf@skynet.be>
Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
parent aec71382
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1703,7 +1703,7 @@ static int build_curseg(struct f2fs_sb_info *sbi)
	struct curseg_info *array;
	int i;

	array = kzalloc(sizeof(*array) * NR_CURSEG_TYPE, GFP_KERNEL);
	array = kcalloc(NR_CURSEG_TYPE, sizeof(*array), GFP_KERNEL);
	if (!array)
		return -ENOMEM;