File autofs-5.0.6-invalid-ghost-dirs.patch of Package autofs
From: Leonardo Chiquitto <lchiquitto@novell.com>
References: bnc#658734
When ghosting is enabled, don't create mount points for cached entries
that don't have a valid mapent.
Submitted upstream:
http://linux.kernel.org/pipermail/autofs/2010-December/006279.html
---
daemon/lookup.c | 3 +++
1 file changed, 3 insertions(+)
Index: autofs-5.0.6/daemon/lookup.c
===================================================================
--- autofs-5.0.6.orig/daemon/lookup.c
+++ autofs-5.0.6/daemon/lookup.c
@@ -607,6 +607,9 @@ int lookup_ghost(struct autofs_point *ap
if (!strcmp(me->key, "*"))
goto next;
+ if (!me->mapent)
+ goto next;
+
if (*me->key == '/') {
/* It's a busy multi-mount - leave till next time */
if (list_empty(&me->multi_list))