summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/execute.c3
-rw-r--r--src/core/main.c3
-rw-r--r--src/core/namespace.c3
-rw-r--r--src/core/service.c7
4 files changed, 5 insertions, 11 deletions
diff --git a/src/core/execute.c b/src/core/execute.c
index cd3592b847..6abb0a5d5d 100644
--- a/src/core/execute.c
+++ b/src/core/execute.c
@@ -1998,9 +1998,8 @@ void exec_context_done(ExecContext *c) {
strv_free(c->environment_files);
c->environment_files = NULL;
- for (l = 0; l < ELEMENTSOF(c->rlimit); l++) {
+ for (l = 0; l < ELEMENTSOF(c->rlimit); l++)
c->rlimit[l] = mfree(c->rlimit[l]);
- }
c->working_directory = mfree(c->working_directory);
c->root_directory = mfree(c->root_directory);
diff --git a/src/core/main.c b/src/core/main.c
index 9aaf244e71..8cf1bebc67 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -1841,9 +1841,8 @@ finish:
arg_shutdown_watchdog = m->shutdown_watchdog;
m = manager_free(m);
- for (j = 0; j < ELEMENTSOF(arg_default_rlimit); j++) {
+ for (j = 0; j < ELEMENTSOF(arg_default_rlimit); j++)
arg_default_rlimit[j] = mfree(arg_default_rlimit[j]);
- }
arg_default_unit = mfree(arg_default_unit);
diff --git a/src/core/namespace.c b/src/core/namespace.c
index 5ff35b38fb..eb88574f8f 100644
--- a/src/core/namespace.c
+++ b/src/core/namespace.c
@@ -555,10 +555,9 @@ int setup_namespace(
/* Remount / as the desired mode. Not that this will not
* reestablish propagation from our side to the host, since
* what's disconnected is disconnected. */
- if (mount(NULL, "/", NULL, mount_flags | MS_REC, NULL) < 0) {
+ if (mount(NULL, "/", NULL, mount_flags | MS_REC, NULL) < 0)
/* at this point, we cannot rollback */
return -errno;
- }
return 0;
diff --git a/src/core/service.c b/src/core/service.c
index e396dbe213..248a9e8c62 100644
--- a/src/core/service.c
+++ b/src/core/service.c
@@ -2937,14 +2937,11 @@ static void service_notify_message(Unit *u, pid_t pid, char **tags, FDSet *fds)
}
/* Interpret WATCHDOG= */
- if (strv_find(tags, "WATCHDOG=1")) {
+ if (strv_find(tags, "WATCHDOG=1"))
service_reset_watchdog(s);
- }
- /* Add the passed fds to the fd store */
- if (strv_find(tags, "FDSTORE=1")) {
+ if (strv_find(tags, "FDSTORE=1"))
service_add_fd_store_set(s, fds);
- }
/* Notify clients about changed status or main pid */
if (notify_dbus)