Ian Kent ab7ff7
autofs-5.0.5 - always read file maps mount lookup map read fix
Ian Kent ab7ff7
Ian Kent ab7ff7
From: Ian Kent <raven@themaw.net>
Ian Kent ab7ff7
Ian Kent ab7ff7
If, during a mount lookup, a file map is found to have changed and the
Ian Kent ab7ff7
browse option is not being used, the file map won't be refreshed, even
Ian Kent ab7ff7
though file maps should always be read into the cache.
Ian Kent ab7ff7
Ian Kent ab7ff7
A previous change for the "always read file maps" optimization moved
Ian Kent ab7ff7
the check for the browse option into the map module read function so
Ian Kent ab7ff7
checking for this in send_map_update_request() is not needed and
Ian Kent ab7ff7
causes nobrowse file maps to not be read if they have changed. This
Ian Kent ab7ff7
isn't quite optimal as there will be a partial read of the file map
Ian Kent ab7ff7
to satisfy the lookup and a full read of the map done by the queued
Ian Kent ab7ff7
update request. I don't think anything can be done about that though.
Ian Kent ab7ff7
---
Ian Kent ab7ff7
Ian Kent ab7ff7
 CHANGELOG    |    1 +
Ian Kent ab7ff7
 lib/master.c |    3 ---
Ian Kent ab7ff7
 2 files changed, 1 insertion(+), 3 deletions(-)
Ian Kent ab7ff7
Ian Kent ab7ff7
Ian Kent ab7ff7
--- autofs-5.0.5.orig/CHANGELOG
Ian Kent ab7ff7
+++ autofs-5.0.5/CHANGELOG
Ian Kent ab7ff7
@@ -49,6 +49,7 @@
Ian Kent ab7ff7
 - remove ERR_remove_state() openssl call.
Ian Kent ab7ff7
 - fix init script restart option.
Ian Kent ab7ff7
 - fix init script status privilege error.
Ian Kent ab7ff7
+- always read file maps mount lookup map read fix.
Ian Kent ab7ff7
 
Ian Kent ab7ff7
 03/09/2009 autofs-5.0.5
Ian Kent ab7ff7
 -----------------------
Ian Kent ab7ff7
--- autofs-5.0.5.orig/lib/master.c
Ian Kent ab7ff7
+++ autofs-5.0.5/lib/master.c
Ian Kent ab7ff7
@@ -489,9 +489,6 @@ void send_map_update_request(struct auto
Ian Kent ab7ff7
 	struct map_source *map;
Ian Kent ab7ff7
 	int status, need_update = 0;
Ian Kent ab7ff7
 
Ian Kent ab7ff7
-	if (!(ap->flags & MOUNT_FLAG_GHOST))
Ian Kent ab7ff7
-		return;
Ian Kent ab7ff7
-
Ian Kent ab7ff7
 	status = pthread_mutex_lock(&instance_mutex);
Ian Kent ab7ff7
 	if (status)
Ian Kent ab7ff7
 		fatal(status);