[PATCH v4 38/59] fspick(2): use CLASS(filename_flags)

Al Viro
2026-01-08T07:36:56Z

That kills the last place where we mix LOOKUP_EMPTY with lookup
flags proper.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
fs/fsopen.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/fsopen.c b/fs/fsopen.c
index f645c99204eb..70f4ab183c9e 100644
--- a/fs/fsopen.c
+++ b/fs/fsopen.c
@@ -181,9 +181,9 @@ SYSCALL_DEFINE3(fspick, int, dfd, const char __user *, path, unsigned int, flags
lookup_flags &= ~LOOKUP_FOLLOW;
if (flags & FSPICK_NO_AUTOMOUNT)
lookup_flags &= ~LOOKUP_AUTOMOUNT;
- if (flags & FSPICK_EMPTY_PATH)
- lookup_flags |= LOOKUP_EMPTY;
- ret = user_path_at(dfd, path, lookup_flags, &target);
+ CLASS(filename_flags, filename)(path,
+ (flags & FSPICK_EMPTY_PATH) ? LOOKUP_EMPTY : 0);
+ ret = filename_lookup(dfd, filename, lookup_flags, &target, NULL);
if (ret < 0)
goto err;

--
2.47.3