autofs-5.0.1 - check replicated list after probe From: Ian Kent <raven@themaw.net> When checking a list of servers for proximity and NFS version the list may become empty after after the initial probe. This case isn't handled and this patch adds it. --- modules/replicated.c | 9 +++++++++ 1 file changed, 9 insertions(+) --- autofs-5.0.1.orig/modules/replicated.c +++ autofs-5.0.1/modules/replicated.c @@ -758,6 +758,15 @@ int prune_host_list(unsigned logopt, str this = next; } + /* + * The list of hosts that aren't proximity local may now + * be empty if we haven't been able probe any so we need + * to check again for a list containing only proximity + * local hosts. + */ + if (!first) + return 1; + last = this; /* Select NFS version of highest number of closest servers */