]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
manager: fix handling of failure in initialization
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 22 Jan 2017 06:35:33 +0000 (01:35 -0500)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 11 Feb 2017 23:21:06 +0000 (18:21 -0500)
We would warn and continue after failure in manager_startup, but there's no
way we can continue. We must fail.

src/core/main.c

index ad2ce1330ee0362dde477040bee762cae1358637..3c6b18229c841d637b6473a49acc7b598b2335da 100644 (file)
@@ -1830,8 +1830,10 @@ int main(int argc, char *argv[]) {
         before_startup = now(CLOCK_MONOTONIC);
 
         r = manager_startup(m, arg_serialization, fds);
-        if (r < 0)
+        if (r < 0) {
                 log_error_errno(r, "Failed to fully start up daemon: %m");
+                goto finish;
+        }
 
         /* This will close all file descriptors that were opened, but
          * not claimed by any unit. */