diff options
author | Fuqian Huang <huangfq.daxian@gmail.com> | 2019-07-03 15:17:27 +0200 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2019-07-03 16:24:25 +0200 |
commit | 90f15ac9fa7e7ff66e0980309d8184bff0611624 (patch) | |
tree | 7a486f87d06779c52b6ebb2ea95383d84fbcda68 /fs/udf/inode.c | |
parent | quota: honor quota type in Q_XGETQSTAT[V] calls (diff) | |
download | linux-90f15ac9fa7e7ff66e0980309d8184bff0611624.tar.xz linux-90f15ac9fa7e7ff66e0980309d8184bff0611624.zip |
ext2: Use kmemdup rather than duplicating its implementation
kmemdup is introduced to duplicate a region of memory in a neat way.
Rather than kmalloc/kzalloc + memset, which the programmer needs to
write the size twice (sometimes lead to mistakes), kmemdup improves
readability, leads to smaller code and also reduce the chances of mistakes.
Suggestion to use kmemdup rather than using kmalloc/kzalloc + memset.
Signed-off-by: Fuqian Huang <huangfq.daxian@gmail.com>
Link: https://lore.kernel.org/r/20190703131727.25735-1-huangfq.daxian@gmail.com
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions