From 672f89e96aa251c3174d340541609e100882172c Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 26 Feb 2014 04:28:37 +0100 Subject: [PATCH] mount: don't fire PropertiesChanged signals for mounts that are stopped (cherry picked from commit aef831369cd2a7a1bd4a58dd96ff8628ed6a85f9) --- src/core/mount.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/core/mount.c b/src/core/mount.c index 0a0ef82..65ea3f9 100644 --- a/src/core/mount.c +++ b/src/core/mount.c @@ -1691,20 +1691,20 @@ void mount_fd_event(Manager *m, int events) { Mount *mount = MOUNT(u); if (!mount->is_mounted) { - /* This has just been unmounted. */ mount->from_proc_self_mountinfo = false; switch (mount->state) { case MOUNT_MOUNTED: + /* This has just been unmounted by + * somebody else, follow the state + * change. */ mount_enter_dead(mount, MOUNT_SUCCESS); break; default: - mount_set_state(mount, mount->state); break; - } } else if (mount->just_mounted || mount->just_changed) { @@ -1715,6 +1715,9 @@ void mount_fd_event(Manager *m, int events) { case MOUNT_DEAD: case MOUNT_FAILED: + /* This has just been mounted by + * somebody else, follow the state + * change. */ mount_enter_mounted(mount, MOUNT_SUCCESS); break;