diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2021-04-27 14:22:34 +0900 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2021-04-28 17:36:09 +0200 |
commit | 255b1fc8a3055a7d59946a0fc483ee3885740398 (patch) | |
tree | 7c7d5ee14440f44c5fcbc548c9e8953e8834f8a5 /src/systemctl/systemctl.c | |
parent | feb10c665f8cdd8bd1cc12a4584910ad702c1b5a (diff) | |
download | systemd-255b1fc8a3055a7d59946a0fc483ee3885740398.tar.gz |
bus-print-property: introduce BusPrintPropertyFlags
Follow-ups for 1ceaad69378272c64da4ecaab0d59ebb7a92ca0a.
Diffstat (limited to 'src/systemctl/systemctl.c')
-rw-r--r-- | src/systemctl/systemctl.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c index bcc5f896b9..16c1f39440 100644 --- a/src/systemctl/systemctl.c +++ b/src/systemctl/systemctl.c @@ -75,7 +75,7 @@ bool arg_no_wtmp = false; bool arg_no_sync = false; bool arg_no_wall = false; bool arg_no_reload = false; -bool arg_value = false; +BusPrintPropertyFlags arg_print_flags = 0; bool arg_show_types = false; int arg_check_inhibitors = -1; bool arg_dry_run = false; @@ -541,7 +541,7 @@ static int systemctl_parse_argv(int argc, char *argv[]) { break; case 'P': - arg_value = true; + SET_FLAG(arg_print_flags, BUS_PRINT_PROPERTY_ONLY_VALUE, true); _fallthrough_; case 'p': @@ -566,11 +566,12 @@ static int systemctl_parse_argv(int argc, char *argv[]) { } /* If the user asked for a particular property, show it, even if it is empty. */ - arg_all = true; + SET_FLAG(arg_print_flags, BUS_PRINT_PROPERTY_SHOW_EMPTY, true); break; case 'a': + SET_FLAG(arg_print_flags, BUS_PRINT_PROPERTY_SHOW_EMPTY, true); arg_all = true; break; @@ -593,7 +594,7 @@ static int systemctl_parse_argv(int argc, char *argv[]) { break; case ARG_VALUE: - arg_value = true; + SET_FLAG(arg_print_flags, BUS_PRINT_PROPERTY_ONLY_VALUE, true); break; case ARG_JOB_MODE: |