automount: never consider our own mount point a prefix mount of us

This commit is contained in:
Lennart Poettering 2010-05-19 03:42:05 +02:00
parent c8513d54d2
commit 1b5601907e
2 changed files with 7 additions and 1 deletions

3
fixme
View File

@ -65,7 +65,8 @@
* teach dbus to talk to systemd when autospawning services
* unix sockets chown()/chgrp()
* Figure out which signal handlers we actually have to reset in the
forked off child
Regularly:

View File

@ -59,6 +59,8 @@ static void repeat_unmout(const char *path) {
assert(path);
for (;;) {
/* If there are multiple mounts on a mount point, this
* removes them all */
if (umount2(path, MNT_DETACH) >= 0)
continue;
@ -118,6 +120,9 @@ int automount_add_one_mount_link(Automount *a, Mount *m) {
if (!path_startswith(a->where, m->where))
return 0;
if (path_equal(a->where, m->where))
return 0;
if ((r = unit_add_dependency(UNIT(m), UNIT_BEFORE, UNIT(a), true)) < 0)
return r;