From 451e16e0cb56035b01de7d9559eba91247003681 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 19 Mar 2019 13:04:05 +0100 Subject: [PATCH] stdio-bridge: use SYNTHETIC_ERRNO() where appropriate --- src/stdio-bridge/stdio-bridge.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/stdio-bridge/stdio-bridge.c b/src/stdio-bridge/stdio-bridge.c index 323191def6e..16f4bdb8097 100644 --- a/src/stdio-bridge/stdio-bridge.c +++ b/src/stdio-bridge/stdio-bridge.c @@ -109,10 +109,8 @@ static int run(int argc, char *argv[]) { } else if (r == 1) { in_fd = SD_LISTEN_FDS_START; out_fd = SD_LISTEN_FDS_START; - } else { - log_error("Illegal number of file descriptors passed."); - return -EINVAL; - } + } else + return log_error_errno(SYNTHETIC_ERRNO(EINVAL), "Illegal number of file descriptors passed."); is_unix = sd_is_socket(in_fd, AF_UNIX, 0, 0) > 0 && -- 2.47.3