Skip to content
Commit 3bdba28b authored by Al Viro's avatar Al Viro
Browse files

namei: lift link_path_walk() call out of trailing_symlink()



Make trailing_symlink() return the pathname to traverse or ERR_PTR(-E...).
A subtle point is that for "magic" symlinks it returns "" now - that
leads to link_path_walk("", nd), which is immediately returning 0 and
we are back to the treatment of the last component, at whereever the
damn thing has left us.

Reduces the stack footprint - link_path_walk() called on more shallow
stack now.

Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 368ee9ba
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment