From 89ffcd2ad5bf87866314e96c4179ba622851cd6e Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 20 Mar 2013 22:56:25 +0100 Subject: bus: hook up client with socket communication --- src/libsystemd-bus/bus-internal.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/libsystemd-bus/bus-internal.h') diff --git a/src/libsystemd-bus/bus-internal.h b/src/libsystemd-bus/bus-internal.h index d8cdc48ce0..9a12d661e1 100644 --- a/src/libsystemd-bus/bus-internal.h +++ b/src/libsystemd-bus/bus-internal.h @@ -50,8 +50,7 @@ enum bus_state { BUS_OPENING, BUS_AUTHENTICATING, BUS_HELLO, - BUS_RUNNING, - BUS_CLOSED + BUS_RUNNING }; struct sd_bus { @@ -60,7 +59,7 @@ struct sd_bus { int fd; int message_version; bool can_fds:1; - bool send_hello:1; + bool sent_hello:1; void *rbuffer; size_t rbuffer_size; @@ -99,3 +98,9 @@ struct sd_bus { size_t auth_size; char *auth_uid; }; + +static inline void bus_unrefp(sd_bus **b) { + sd_bus_unref(*b); +} + +#define _cleanup_bus_unref_ __attribute__((cleanup(bus_unrefp))) -- cgit v1.2.3-54-g00ecf