diff options
Diffstat (limited to 'src/journal-remote/journal-gatewayd.c')
-rw-r--r-- | src/journal-remote/journal-gatewayd.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/src/journal-remote/journal-gatewayd.c b/src/journal-remote/journal-gatewayd.c index 723b057c1d..d39a2cc67e 100644 --- a/src/journal-remote/journal-gatewayd.c +++ b/src/journal-remote/journal-gatewayd.c @@ -909,10 +909,8 @@ static int parse_argv(int argc, char *argv[]) { return -EINVAL; } r = read_full_file(optarg, &key_pem, NULL); - if (r < 0) { - log_error_errno(r, "Failed to read key file: %m"); - return r; - } + if (r < 0) + return log_error_errno(r, "Failed to read key file: %m"); assert(key_pem); break; @@ -922,10 +920,8 @@ static int parse_argv(int argc, char *argv[]) { return -EINVAL; } r = read_full_file(optarg, &cert_pem, NULL); - if (r < 0) { - log_error_errno(r, "Failed to read certificate file: %m"); - return r; - } + if (r < 0) + return log_error_errno(r, "Failed to read certificate file: %m"); assert(cert_pem); break; @@ -936,10 +932,8 @@ static int parse_argv(int argc, char *argv[]) { return -EINVAL; } r = read_full_file(optarg, &trust_pem, NULL); - if (r < 0) { - log_error_errno(r, "Failed to read CA certificate file: %m"); - return r; - } + if (r < 0) + return log_error_errno(r, "Failed to read CA certificate file: %m"); assert(trust_pem); break; #else |