chiark / gitweb /
core: move status line ellipsation to 50% of the line
[elogind.git] / src / initctl / initctl.c
index f9a6ed44ed5758c7ec9c29a6a76c66746b01c589..0954e58afdb1f260809054b2557f274233b0d7e2 100644 (file)
@@ -218,7 +218,7 @@ static int fifo_process(Fifo *f) {
                         return 0;
 
                 log_warning("Failed to read from fifo: %m");
-                return -1;
+                return -errno;
         }
 
         f->bytes_read += l;
@@ -383,7 +383,8 @@ int main(int argc, char *argv[]) {
 
         umask(0022);
 
-        if ((n = sd_listen_fds(true)) < 0) {
+        n = sd_listen_fds(true);
+        if (n < 0) {
                 log_error("Failed to read listening file descriptors from environment: %s", strerror(-r));
                 return EXIT_FAILURE;
         }