summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-02-26 04:28:37 +0100
committerLennart Poettering <lennart@poettering.net>2014-02-26 04:32:03 +0100
commitaef831369cd2a7a1bd4a58dd96ff8628ed6a85f9 (patch)
tree4e12b74413d4d8d2c62f556f43815a59417aa835
parentff5f34d08c191c326c41a083745522383ac86cae (diff)
mount: don't fire PropertiesChanged signals for mounts that are stopped
-rw-r--r--src/core/mount.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/core/mount.c b/src/core/mount.c
index 98812c9c08..7a92e1ca60 100644
--- a/src/core/mount.c
+++ b/src/core/mount.c
@@ -1679,20 +1679,20 @@ static int mount_dispatch_io(sd_event_source *source, int fd, uint32_t revents,
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) {
@@ -1703,6 +1703,9 @@ static int mount_dispatch_io(sd_event_source *source, int fd, uint32_t revents,
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;