mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-12-27 12:21:22 -05:00
fsconfig: ensure that dirfd is set to aux
The code in fs_param_is_fd() expects param->dirfd to be set to the fd that was used to set param->file to initialize result->uint_32. So make sure it's set so users like autofs using FSCONFIG_SET_FD with the new mount api can rely on this to be set to the correct value. Link: https://lore.kernel.org/lkml/20230922-vorbringen-spaghetti-946729122076@brauner Signed-off-by: Christian Brauner <brauner@kernel.org>
This commit is contained in:
@@ -465,6 +465,7 @@ SYSCALL_DEFINE5(fsconfig,
|
||||
param.file = fget(aux);
|
||||
if (!param.file)
|
||||
goto out_key;
|
||||
param.dirfd = aux;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user