---
 src/core/main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/core/main.c b/src/core/main.c
index cdd77c1..8973637 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -1511,8 +1511,8 @@ int main(int argc, char *argv[]) {
                 /* Become reaper of our children */
                 r = prctl(PR_SET_CHILD_SUBREAPER, 1);
                 if (r < 0)
-                        log_error("Failed to prctl(PR_SET_CHILD_SUBREAPER): 
%s", strerror(-r));
-                if (r == -EINVAL)
+                        log_error("Failed to prctl(PR_SET_CHILD_SUBREAPER): 
%m");
+                if (r < 0 && errno == EINVAL)
                         log_error("Perhaps the kernel version is too old (< 
3.4?)");
         }
 
-- 
1.7.5.2

_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to