summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Kent <raven@themaw.net>2006-09-29 02:00:53 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-09-29 09:18:18 -0700
commitbe3ca7fecb1a9903c6253f49aec0af2a0f3a04e4 (patch)
tree128cc5b9e66dbd426f7200c67eae325ab13cfd5c
parent5b160f5ecd2f1b6df2e0015dc1f319c8ef803d62 (diff)
downloadlinux-3.10-be3ca7fecb1a9903c6253f49aec0af2a0f3a04e4.tar.gz
linux-3.10-be3ca7fecb1a9903c6253f49aec0af2a0f3a04e4.tar.bz2
linux-3.10-be3ca7fecb1a9903c6253f49aec0af2a0f3a04e4.zip
[PATCH] autofs4: autofs4_follow_link false negative fix
The check for an empty directory in the autofs4_follow_link method fails occassionally due to old dentrys. We had the same problem autofs4_revalidate ages ago. I thought we wouldn't need this in autofs4_follow_link, silly me. Signed-off-by: Ian Kent <raven@themaw.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--fs/autofs4/root.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/autofs4/root.c b/fs/autofs4/root.c
index 27e17f96cad..0ec24835239 100644
--- a/fs/autofs4/root.c
+++ b/fs/autofs4/root.c
@@ -359,7 +359,7 @@ static void *autofs4_follow_link(struct dentry *dentry, struct nameidata *nd)
* don't try to mount it again.
*/
spin_lock(&dcache_lock);
- if (!d_mountpoint(dentry) && list_empty(&dentry->d_subdirs)) {
+ if (!d_mountpoint(dentry) && __simple_empty(dentry)) {
spin_unlock(&dcache_lock);
status = try_to_fill_dentry(dentry, 0);