X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Flibsystemd-bus%2Fbus-util.h;h=51e1613c17a0b344019bb9987314332635da6e1b;hb=610f780cd6186073cb7cfe4b5287c261cec7495a;hp=38d468edada426e53a020281539a6af76ba6c9c8;hpb=5fd38859b30b95008e483109578c7fef2b5072f3;p=elogind.git diff --git a/src/libsystemd-bus/bus-util.h b/src/libsystemd-bus/bus-util.h index 38d468eda..51e1613c1 100644 --- a/src/libsystemd-bus/bus-util.h +++ b/src/libsystemd-bus/bus-util.h @@ -52,9 +52,11 @@ int bus_map_all_properties(sd_bus *bus, const struct bus_properties_map *map, void *userdata); -int bus_async_unregister_and_quit(sd_event *e, sd_bus *bus, const char *name); +int bus_async_unregister_and_exit(sd_event *e, sd_bus *bus, const char *name); -int bus_event_loop_with_idle(sd_event *e, sd_bus *bus, const char *name, usec_t timeout); +typedef bool (*check_idle_t)(void *userdata); + +int bus_event_loop_with_idle(sd_event *e, sd_bus *bus, const char *name, usec_t timeout, check_idle_t check_idle, void *userdata); int bus_name_has_owner(sd_bus *c, const char *name, sd_bus_error *error); @@ -137,9 +139,11 @@ int bus_parse_unit_info(sd_bus_message *message, UnitInfo *u); DEFINE_TRIVIAL_CLEANUP_FUNC(sd_bus*, sd_bus_unref); DEFINE_TRIVIAL_CLEANUP_FUNC(sd_bus_message*, sd_bus_message_unref); +DEFINE_TRIVIAL_CLEANUP_FUNC(sd_bus_creds*, sd_bus_creds_unref); #define _cleanup_bus_unref_ _cleanup_(sd_bus_unrefp) #define _cleanup_bus_message_unref_ _cleanup_(sd_bus_message_unrefp) +#define _cleanup_bus_creds_unref_ _cleanup_(sd_bus_creds_unrefp) #define _cleanup_bus_error_free_ _cleanup_(sd_bus_error_free) #define BUS_DEFINE_PROPERTY_GET_ENUM(function, name, type) \