diff options
author | Lennart Poettering <lennart@poettering.net> | 2017-11-10 21:15:44 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2017-11-10 21:15:44 +0100 |
commit | 0b3c84eb7da3a8c28ac248a68228f6a7edbb2e19 (patch) | |
tree | 94a7ea7f1aa53dd2b5b30813688029d4c2401bc6 /src/busctl | |
parent | d13b522751504e6ff5720200622265870dc9c1ad (diff) | |
download | systemd-0b3c84eb7da3a8c28ac248a68228f6a7edbb2e19.tar.gz systemd-0b3c84eb7da3a8c28ac248a68228f6a7edbb2e19.tar.bz2 systemd-0b3c84eb7da3a8c28ac248a68228f6a7edbb2e19.zip |
tree-wide: use _cleanup_(sd_bus_flush_close_unrefp) at various appropriate places
Let's shorten the code a bit.
Diffstat (limited to 'src/busctl')
-rw-r--r-- | src/busctl/busctl.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/busctl/busctl.c b/src/busctl/busctl.c index b38d6c7267..d41ccf30fe 100644 --- a/src/busctl/busctl.c +++ b/src/busctl/busctl.c @@ -2010,7 +2010,7 @@ static int busctl_main(sd_bus *bus, int argc, char *argv[]) { } int main(int argc, char *argv[]) { - sd_bus *bus = NULL; + _cleanup_(sd_bus_flush_close_unrefp) sd_bus *bus = NULL; int r; log_parse_environment(); @@ -2100,7 +2100,6 @@ int main(int argc, char *argv[]) { r = busctl_main(bus, argc, argv); finish: - sd_bus_flush_close_unref(bus); pager_close(); strv_free(arg_matches); |