summaryrefslogtreecommitdiff
path: root/src/stdio-bridge
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2019-03-19 13:04:05 +0100
committerLennart Poettering <lennart@poettering.net>2019-03-19 15:29:44 +0100
commit451e16e0cb56035b01de7d9559eba91247003681 (patch)
tree203971fa260edaaf5ac41a22bac96afd6ffce7f7 /src/stdio-bridge
parentb6056ea37cda628c2053aa3554ac32502b5223ff (diff)
downloadsystemd-451e16e0cb56035b01de7d9559eba91247003681.tar.gz
stdio-bridge: use SYNTHETIC_ERRNO() where appropriate
Diffstat (limited to 'src/stdio-bridge')
-rw-r--r--src/stdio-bridge/stdio-bridge.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/stdio-bridge/stdio-bridge.c b/src/stdio-bridge/stdio-bridge.c
index 323191def6..16f4bdb809 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 &&