|
|
29d2b9 |
autofs-5.1.7 - add set_offset_tree_catatonic()
|
|
|
29d2b9 |
|
|
|
29d2b9 |
From: Ian Kent <raven@themaw.net>
|
|
|
29d2b9 |
|
|
|
29d2b9 |
Add tree mapent support function set_offset_tree_catatonic().
|
|
|
29d2b9 |
|
|
|
29d2b9 |
Signed-off-by: Ian Kent <raven@themaw.net>
|
|
|
29d2b9 |
---
|
|
|
29d2b9 |
CHANGELOG | 1 +
|
|
|
29d2b9 |
lib/mounts.c | 15 +++++++++++++++
|
|
|
29d2b9 |
2 files changed, 16 insertions(+)
|
|
|
29d2b9 |
|
|
|
29d2b9 |
diff --git a/CHANGELOG b/CHANGELOG
|
|
|
29d2b9 |
index 89d4cfa0..0bd6f181 100644
|
|
|
29d2b9 |
--- a/CHANGELOG
|
|
|
29d2b9 |
+++ b/CHANGELOG
|
|
|
29d2b9 |
@@ -38,6 +38,7 @@
|
|
|
29d2b9 |
- add tree_mapent_traverse_subtree().
|
|
|
29d2b9 |
- fix mount_fullpath().
|
|
|
29d2b9 |
- add tree_mapent_cleanup_offsets().
|
|
|
29d2b9 |
+- add set_offset_tree_catatonic().
|
|
|
29d2b9 |
|
|
|
29d2b9 |
25/01/2021 autofs-5.1.7
|
|
|
29d2b9 |
- make bind mounts propagation slave by default.
|
|
|
29d2b9 |
diff --git a/lib/mounts.c b/lib/mounts.c
|
|
|
29d2b9 |
index ba573b9a..f075a27e 100644
|
|
|
29d2b9 |
--- a/lib/mounts.c
|
|
|
29d2b9 |
+++ b/lib/mounts.c
|
|
|
29d2b9 |
@@ -2578,6 +2578,21 @@ static int set_mount_catatonic(struct autofs_point *ap, struct mapent *me, int i
|
|
|
29d2b9 |
return 0;
|
|
|
29d2b9 |
}
|
|
|
29d2b9 |
|
|
|
29d2b9 |
+static int set_offset_tree_catatonic_work(struct tree_node *n, void *ptr)
|
|
|
29d2b9 |
+{
|
|
|
29d2b9 |
+ struct mapent *me = MAPENT(n);
|
|
|
29d2b9 |
+ struct autofs_point *ap = me->mc->ap;
|
|
|
29d2b9 |
+
|
|
|
29d2b9 |
+ set_mount_catatonic(ap, me, me->ioctlfd);
|
|
|
29d2b9 |
+
|
|
|
29d2b9 |
+ return 1;
|
|
|
29d2b9 |
+}
|
|
|
29d2b9 |
+
|
|
|
29d2b9 |
+static void set_offset_tree_catatonic(struct autofs_point *ap, struct mapent *me)
|
|
|
29d2b9 |
+{
|
|
|
29d2b9 |
+ tree_traverse_inorder(MAPENT_ROOT(me), set_offset_tree_catatonic_work, NULL);
|
|
|
29d2b9 |
+}
|
|
|
29d2b9 |
+
|
|
|
29d2b9 |
static void set_multi_mount_tree_catatonic(struct autofs_point *ap, struct mapent *me)
|
|
|
29d2b9 |
{
|
|
|
29d2b9 |
if (!list_empty(&me->multi_list)) {
|