};
typedef enum BusSlotType {
- _BUS_SLOT_DISCONNECTED,
BUS_REPLY_CALLBACK,
BUS_FILTER_CALLBACK,
BUS_MATCH_CALLBACK,
BUS_NODE_ENUMERATOR,
BUS_NODE_VTABLE,
BUS_NODE_OBJECT_MANAGER,
+ _BUS_SLOT_INVALID = -1,
} BusSlotType;
struct sd_bus_slot {
unsigned n_ref;
sd_bus *bus;
void *userdata;
- BusSlotType type;
- bool floating;
+ BusSlotType type:5;
+ bool floating:1;
LIST_FIELDS(sd_bus_slot, slots);
Hashmap *vtable_methods;
Hashmap *vtable_properties;
- union {
- struct sockaddr sa;
- struct sockaddr_un un;
- struct sockaddr_in in;
- struct sockaddr_in6 in6;
- } sockaddr;
+ union sockaddr_union sockaddr;
socklen_t sockaddr_size;
char *kernel;
sd_bus_message *current_message;
sd_bus_slot *current_slot;
+ sd_bus_message_handler_t current_handler;
+ void *current_userdata;
sd_bus **default_bus_ptr;
pid_t tid;
int bus_set_address_system_container(sd_bus *b, const char *machine);
int bus_remove_match_by_string(sd_bus *bus, const char *match, sd_bus_message_handler_t callback, void *userdata);
+
+int bus_get_root_path(sd_bus *bus);