aboutsummaryrefslogtreecommitdiff
path: root/lib/mpi/mpiutil.c
diff options
context:
space:
mode:
authorDarrick J. Wong <[email protected]>2022-03-08 10:50:43 -0800
committerTheodore Ts'o <[email protected]>2022-04-12 22:22:02 -0400
commitad5cd4f4ee4d5fcdb1bfb7a0c073072961e70783 (patch)
tree327d0219545bfb055b6af9985bdf9194361e2112 /lib/mpi/mpiutil.c
parent919adbfec29d5b89b3e45620653cbeeb0d42e6fd (diff)
ext4: fix fallocate to use file_modified to update permissions consistently
Since the initial introduction of (posix) fallocate back at the turn of the century, it has been possible to use this syscall to change the user-visible contents of files. This can happen by extending the file size during a preallocation, or through any of the newer modes (punch, zero, collapse, insert range). Because the call can be used to change file contents, we should treat it like we do any other modification to a file -- update the mtime, and drop set[ug]id privileges/capabilities. The VFS function file_modified() does all this for us if pass it a locked inode, so let's make fallocate drop permissions correctly. Signed-off-by: Darrick J. Wong <[email protected]> Link: https://lore.kernel.org/r/20220308185043.GA117678@magnolia Signed-off-by: Theodore Ts'o <[email protected]> Cc: [email protected]
Diffstat (limited to 'lib/mpi/mpiutil.c')
0 files changed, 0 insertions, 0 deletions