diff options
author | Philipp Stanner <pstanner@redhat.com> | 2023-11-07 01:44:16 +0300 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2023-12-11 04:21:25 +0300 |
commit | 44e3876d268be49ee810481ee3c95d8d650bf22e (patch) | |
tree | 8f11d2f6dee12a9265b7f48dca5b545f1348fb63 /fs/binfmt_script.c | |
parent | 61a7a5e25fe79b6c43f1c49705a0294be113c4a5 (diff) | |
download | linux-44e3876d268be49ee810481ee3c95d8d650bf22e.tar.xz |
fs/nilfs2: use standard array-copy-function
ioctl.c utilizes memdup_user() to copy a userspace array. An overflow
check is performed manually before the function's invocation.
The new function memdup_array_user() standardizes copying userspace
arrays, thus, improving readability by making it more clear that an array
is being copied. Additionally, it also performs an overflow check.
Remove the (now redundant) manual overflow-check and replace memdup_user()
with memdup_array_user().
In addition, improve the grammar of the comment above
memdup_array_user().
Link: https://lkml.kernel.org/r/20231106224416.3055-1-konishi.ryusuke@gmail.com
Signed-off-by: Philipp Stanner <pstanner@redhat.com>
Link: https://lkml.kernel.org/r/20231103184831.99406-2-pstanner@redhat.com
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Suggested-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'fs/binfmt_script.c')
0 files changed, 0 insertions, 0 deletions