diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2023-04-04 19:39:04 +0200 |
---|---|---|
committer | Mike Yuan <me@yhndnzj.com> | 2023-04-05 13:06:26 +0800 |
commit | 51214cf49195b645bd58b0c41046470908de71d9 (patch) | |
tree | 458ded0c5ca7807fe2bd38de631756784bcbd97a /src/creds | |
parent | 96181b7a893da444fa9adcd1e7c95769d97c2a95 (diff) | |
download | systemd-51214cf49195b645bd58b0c41046470908de71d9.tar.gz |
various: simplify calls to parse_boolean_argument()
parse_boolean_argument() returns the same information via both the output
argument and normal return.
Diffstat (limited to 'src/creds')
-rw-r--r-- | src/creds/creds.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/creds/creds.c b/src/creds/creds.c index 3eb94cd36a..ef32efe1e2 100644 --- a/src/creds/creds.c +++ b/src/creds/creds.c @@ -807,13 +807,11 @@ static int parse_argv(int argc, char *argv[]) { if (isempty(optarg) || streq(optarg, "auto")) arg_newline = -1; else { - bool b; - - r = parse_boolean_argument("--newline=", optarg, &b); + r = parse_boolean_argument("--newline=", optarg, NULL); if (r < 0) return r; - arg_newline = b; + arg_newline = r; } break; |