chiark / gitweb /
sd-event: implicitly set signal event source's descriptions to the signal name
[elogind.git] / src / core / mount.c
index f3ec7365d15178e9d3e1808cda1856c42b94cd1b..01243c381abf892694ed9949b759ec82f3a0a105 100644 (file)
@@ -775,7 +775,8 @@ static void mount_enter_signal(Mount *m, MountState state, MountResult f) {
         r = unit_kill_context(
                         UNIT(m),
                         &m->kill_context,
-                        state != MOUNT_MOUNTING_SIGTERM && state != MOUNT_UNMOUNTING_SIGTERM && state != MOUNT_REMOUNTING_SIGTERM,
+                        (state != MOUNT_MOUNTING_SIGTERM && state != MOUNT_UNMOUNTING_SIGTERM && state != MOUNT_REMOUNTING_SIGTERM) ?
+                        KILL_KILL : KILL_TERMINATE,
                         -1,
                         m->control_pid,
                         false);
@@ -903,10 +904,10 @@ static void mount_enter_mounting(Mount *m) {
                                 m->control_command,
                                 "/bin/mount",
                                 m->sloppy_options ? "-ns" : "-n",
-                                "-t", m->parameters_fragment.fstype ? m->parameters_fragment.fstype : "auto",
-                                "-o", m->parameters_fragment.options ? m->parameters_fragment.options : "",
                                 m->parameters_fragment.what,
                                 m->where,
+                                "-t", m->parameters_fragment.fstype ? m->parameters_fragment.fstype : "auto",
+                                m->parameters_fragment.options ? "-o" : NULL, m->parameters_fragment.options,
                                 NULL);
         else
                 r = -ENOENT;
@@ -951,10 +952,10 @@ static void mount_enter_remounting(Mount *m) {
                                 m->control_command,
                                 "/bin/mount",
                                 m->sloppy_options ? "-ns" : "-n",
-                                "-t", m->parameters_fragment.fstype ? m->parameters_fragment.fstype : "auto",
-                                "-o", o,
                                 m->parameters_fragment.what,
                                 m->where,
+                                "-t", m->parameters_fragment.fstype ? m->parameters_fragment.fstype : "auto",
+                                "-o", o,
                                 NULL);
         } else
                 r = -ENOENT;