mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-10 15:58:47 +00:00
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: Fabian Frederick <fabf@skynet.be> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
aec71382c6
commit
b434babf85
@ -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;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user