summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2017-02-28 16:08:21 +0100
committerLennart Poettering <lennart@poettering.net>2017-02-28 16:08:21 +0100
commite8b509d3bec0cd32746315cf83c79cc3a7618c9c (patch)
treef8b1e06362d67bc5d15c9e0f2a6362baff60352a
parent7c102d60925a9af92c192ebae4d088c7618874a2 (diff)
service: make use of log_unit_warning_errno()'s return value
-rw-r--r--src/core/service.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/core/service.c b/src/core/service.c
index 3f87e08369..5bc8df3e1c 100644
--- a/src/core/service.c
+++ b/src/core/service.c
@@ -849,11 +849,8 @@ static int service_load_pid_file(Service *s, bool may_warn) {
return r;
r = unit_watch_pid(UNIT(s), pid);
- if (r < 0) {
- /* FIXME: we need to do something here */
- log_unit_warning_errno(UNIT(s), r, "Failed to watch PID "PID_FMT" for service: %m", pid);
- return r;
- }
+ if (r < 0) /* FIXME: we need to do something here */
+ return log_unit_warning_errno(UNIT(s), r, "Failed to watch PID "PID_FMT" for service: %m", pid);
return 0;
}
@@ -1374,8 +1371,7 @@ static int service_spawn(
return r;
r = unit_watch_pid(UNIT(s), pid);
- if (r < 0)
- /* FIXME: we need to do something here */
+ if (r < 0) /* FIXME: we need to do something here */
return r;
*_pid = pid;