aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIan Kent <raven@themaw.net>2021-02-20 09:16:56 +0800
committerIan Kent <raven@themaw.net>2021-03-15 07:36:09 +0800
commit47ef717b8b822866ea4ba0b43514c834110fc065 (patch)
tree49b93c6c698cff940d9df1792816c6559d0bfab5
parente44a88a27a9f768289b0bf2ebc63870f0c0b0e42 (diff)
downloadautofs-47ef717b8b822866ea4ba0b43514c834110fc065.tar.gz
autofs-5.1.7 - fix return from umount_subtree_mounts() on offset list delete
When there are no mounts left in a subtree of offset mounts the offset list is deleted. If all goes well deleting the list this shouldn't cause a positive return from umount_subtree_mounts() (essentially saying that the umount of the subtree has not succeeded). Signed-off-by: Ian Kent <raven@themaw.net>
-rw-r--r--CHANGELOG1
-rw-r--r--daemon/automount.c5
2 files changed, 4 insertions, 2 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 64e619ec..6e0edd74 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -16,6 +16,7 @@
- simplify mount_subtree() mount check.
- fix mnts_get_expire_list() expire list construction.
- fix inconsistent locking in umount_subtree_mounts().
+- fix return from umount_subtree_mounts() on offset list delete.
25/01/2021 autofs-5.1.7
- make bind mounts propagation slave by default.
diff --git a/daemon/automount.c b/daemon/automount.c
index 93bd8556..62530b6b 100644
--- a/daemon/automount.c
+++ b/daemon/automount.c
@@ -590,9 +590,10 @@ static int umount_subtree_mounts(struct autofs_point *ap, const char *path, unsi
if (!left && is_mm_root) {
status = cache_delete_offset_list(mc, me->key);
- if (status != CHE_OK)
+ if (status != CHE_OK) {
warn(ap->logopt, "couldn't delete offset list");
- left++;
+ left++;
+ }
}
if (ap->entry->maps &&