]> git.michaelhowe.org Git - packages/o/openafs.git/commit
LINUX: Avoid symlink-y resolution limits
authorAndrew Deason <adeason@sinenomine.net>
Tue, 21 Aug 2012 22:03:30 +0000 (17:03 -0500)
committerDerrick Brashear <shadow@your-file-system.com>
Tue, 2 Oct 2012 20:18:40 +0000 (13:18 -0700)
commit2e7f249e3fa165874a449d9deeb8515481e7375b
tree3bbb738624906d15c6dff520d821b8efc876c7bc
parent6c22f2e1de91fa3080221df22fdcd05064b57307
LINUX: Avoid symlink-y resolution limits

Implementing the d_automount or follow_link function pointers for our
directories means that we can hit symlink resolution limits during
lookup, since we look like a "symlink". We can hit these limits pretty
easily if there are just too many directories in the lookup path.

Our pseudo-symlink directories cannot contribute to an infinite
resolution loop, since our destination is always an actual directory,
not a symlink that will result in more redirection. So, decrement the
total_link_count counter when our d_automount or follow_link code is
reached, so we do not contribute to hitting the max resolution limit.

Note that this is not related to recursive symlink lookup (link_count)
but only to the iterative symlink limit (total_link_count). Our
lookups are not recursive here, and we are not causing more recursive
lookups like a normal text-based symlink would do.

Reviewed-on: http://gerrit.openafs.org/8009
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
(cherry picked from commit 238b88624a8fef39557d397cc336c88bd8efc5b1)

Change-Id: Iec6e3fac25ab86ef5f10f359344908398bef8828
Reviewed-on: http://gerrit.openafs.org/8194
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
src/afs/LINUX/osi_vnodeops.c