path: root/src/cgroups-agent
diff options
authorLennart Poettering <>2015-07-03 19:49:03 +0200
committerSven Eden <>2017-03-14 10:05:55 +0100
commitb767c85a403ee56b5f87bc9414638b857dabd18d (patch)
tree484271f6ff6a5070c93ca5852a9c895f7fc35a99 /src/cgroups-agent
parent688fcb6e06c09634c9084fed3c20d792bdccb413 (diff)
sd-bus: introduce new sd_bus_flush_close_unref() call
sd_bus_flush_close_unref() is a call that simply combines sd_bus_flush() (which writes all unwritten messages out) + sd_bus_close() (which terminates the connection, releasing all unread messages) + sd_bus_unref() (which frees the connection). The combination of this call is used pretty frequently in systemd tools right before exiting, and should also be relevant for most external clients, and is hence useful to cover in a call of its own. Previously the combination of the three calls was already done in the _cleanup_bus_close_unref_ macro, but this was only available internally. Also see #327
Diffstat (limited to 'src/cgroups-agent')
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cgroups-agent/cgroups-agent.c b/src/cgroups-agent/cgroups-agent.c
index 3be4cff80..cca5cec3d 100644
--- a/src/cgroups-agent/cgroups-agent.c
+++ b/src/cgroups-agent/cgroups-agent.c
@@ -26,7 +26,7 @@
#include "bus-util.h"
int main(int argc, char *argv[]) {
- _cleanup_bus_close_unref_ sd_bus *bus = NULL;
+ _cleanup_bus_flush_close_unref_ sd_bus *bus = NULL;
int r;
if (argc != 2) {