]> www.infradead.org Git - users/jedix/linux-maple.git/commit
vfs: reorder checks in may_create_in_sticky
authorMateusz Guzik <mjguzik@gmail.com>
Thu, 20 Jun 2024 12:03:59 +0000 (14:03 +0200)
committerChristian Brauner <brauner@kernel.org>
Tue, 25 Jun 2024 09:15:47 +0000 (11:15 +0200)
commit5e362bd5eecdd7ccafc9611a108a53423ccd5065
tree7b6dde351dcc0191e1b87fe7c1768d1f9beafc14
parent26a2ed107929a855155429b11e1293b83e6b2a8b
vfs: reorder checks in may_create_in_sticky

The routine is called for all directories on file creation and weirdly
postpones the check if the dir is sticky to begin with. Instead it first
checks fifos and regular files (in that order), while avoidably pulling
globals.

No functional changes.

Signed-off-by: Mateusz Guzik <mjguzik@gmail.com>
Link: https://lore.kernel.org/r/20240620120359.151258-1-mjguzik@gmail.com
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/namei.c