projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bba1cb1
)
fs/ocfs2/slot_map.c: replace count*size kzalloc by kcalloc
author
Fabian Frederick
<
[email protected]
>
Wed, 6 Aug 2014 23:04:01 +0000
(16:04 -0700)
committer
Linus Torvalds
<
[email protected]
>
Thu, 7 Aug 2014 01:01:13 +0000
(18:01 -0700)
kcalloc manages count*sizeof overflow.
Signed-off-by: Fabian Frederick <
[email protected]
>
Cc: Mark Fasheh <
[email protected]
>
Cc: Joel Becker <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
fs/ocfs2/slot_map.c
patch
|
blob
|
history
diff --git
a/fs/ocfs2/slot_map.c
b/fs/ocfs2/slot_map.c
index 1424c151cccce0170819ce4e0f36dad7d97461b8..a88b2a4fcc85171210cd17f8e4f9a791d5aa1d2b 100644
(file)
--- a/
fs/ocfs2/slot_map.c
+++ b/
fs/ocfs2/slot_map.c
@@
-382,7
+382,7
@@
static int ocfs2_map_slot_buffers(struct ocfs2_super *osb,
trace_ocfs2_map_slot_buffers(bytes, si->si_blocks);
- si->si_bh = k
zalloc(sizeof(struct buffer_head *) * si->si_blocks
,
+ si->si_bh = k
calloc(si->si_blocks, sizeof(struct buffer_head *)
,
GFP_KERNEL);
if (!si->si_bh) {
status = -ENOMEM;