Blame SOURCES/autofs-5.1.8-fix-nonstrict-fail-handling-of-last-offset-mount.patch

91594d
autofs-5.1.8 - fix nonstrict fail handling of last offset mount
91594d
91594d
From: Ian Kent <raven@themaw.net>
91594d
91594d
When mounting a list of multi-mount offsets the offset mount should
91594d
succeed even if there's a mount failure for the non-strict case (the
91594d
default).
91594d
91594d
But currently if the last offset mount fails the multi-mount fails
91594d
regardless of whether the mount is non-strict or not.
91594d
91594d
Signed-off-by: Ian Kent <raven@themaw.net>
91594d
---
91594d
 CHANGELOG    |    1 +
91594d
 lib/mounts.c |    2 +-
91594d
 2 files changed, 2 insertions(+), 1 deletion(-)
91594d
91594d
--- autofs-5.1.7.orig/CHANGELOG
91594d
+++ autofs-5.1.7/CHANGELOG
91594d
@@ -86,6 +86,7 @@
91594d
 - improve descriptor open error reporting.
91594d
 - fix root offset error handling.
91594d
 - fix fix root offset error handling.
91594d
+- fix nonstrict fail handling of last offset mount.
91594d
 
91594d
 25/01/2021 autofs-5.1.7
91594d
 - make bind mounts propagation slave by default.
91594d
--- autofs-5.1.7.orig/lib/mounts.c
91594d
+++ autofs-5.1.7/lib/mounts.c
91594d
@@ -1940,7 +1940,7 @@ static int tree_mapent_mount_offsets_wor
91594d
 			tree_mapent_mount_offsets(oe, !ctxt->strict);
91594d
 	}
91594d
 
91594d
-	return ret;
91594d
+	return (ctxt->strict ? ret : 1);
91594d
 }
91594d
 
91594d
 int tree_mapent_mount_offsets(struct mapent *oe, int nonstrict)