aboutsummaryrefslogtreecommitdiffstats
path: root/mm/mmap.c
diff options
context:
space:
mode:
authorKari Argillander <kari.argillander@gmail.com>2021-08-25 21:24:35 +0300
committerKonstantin Komarov <almaz.alexandrovich@paragon-software.com>2021-09-02 18:51:00 +0300
commitd4e8e135a9af7d8d939bba1874ab314322fc2dc2 (patch)
treecf9fc5b6972a8024f324aed3d02970aaa2ac962d /mm/mmap.c
parentfs/ntfs3: Restyle comments to better align with kernel-doc (diff)
downloadlinux-dev-d4e8e135a9af7d8d939bba1874ab314322fc2dc2.tar.xz
linux-dev-d4e8e135a9af7d8d939bba1874ab314322fc2dc2.zip
fs/ntfs3: Fix integer overflow in ni_fiemap with fiemap_prep()
Use fiemap_prep() to check valid flags. It also shrink request scope (@len) to what the fs can actually handle. This address following Smatch static checker warning: fs/ntfs3/frecord.c:1894 ni_fiemap() warn: potential integer overflow from user 'vbo + len' Because fiemap_prep() shrinks @len this cannot happened anymore. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Link: lore.kernel.org/ntfs3/20210825080440.GA17407@kili/ Fixes: 4342306f0f0d ("fs/ntfs3: Add file operations and implementation") Signed-off-by: Kari Argillander <kari.argillander@gmail.com> Signed-off-by: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Diffstat (limited to 'mm/mmap.c')
0 files changed, 0 insertions, 0 deletions