summaryrefslogtreecommitdiff
path: root/src/systemd
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2017-12-15 22:24:52 +0100
committerLennart Poettering <lennart@poettering.net>2018-01-05 13:55:08 +0100
commit8a5cd31e5fa0b1313a196b902e4b3c4603e7dfdf (patch)
tree2b2abd84deac871c259ed03fd639caf936017770 /src/systemd
parent5b5e6deabb8b76bcd691c4e40429bd8478a49a32 (diff)
downloadsystemd-8a5cd31e5fa0b1313a196b902e4b3c4603e7dfdf.tar.gz
sd-bus: optionally, use inotify to wait for bus sockets to appear
This adds a "watch-bind" feature to sd-bus connections. If set and the AF_UNIX socket we are connecting to doesn't exist yet, we'll establish an inotify watch instead, and wait for the socket to appear. In other words, a missing AF_UNIX just makes connecting slower. This is useful for daemons such as networkd or resolved that shall be able to run during early-boot, before dbus-daemon is up, and want to connect to dbus-daemon as soon as it becomes ready.
Diffstat (limited to 'src/systemd')
-rw-r--r--src/systemd/sd-bus.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/systemd/sd-bus.h b/src/systemd/sd-bus.h
index c5c7096d55..66bc48842b 100644
--- a/src/systemd/sd-bus.h
+++ b/src/systemd/sd-bus.h
@@ -150,8 +150,10 @@ int sd_bus_set_allow_interactive_authorization(sd_bus *bus, int b);
int sd_bus_get_allow_interactive_authorization(sd_bus *bus);
int sd_bus_set_exit_on_disconnect(sd_bus *bus, int b);
int sd_bus_get_exit_on_disconnect(sd_bus *bus);
+int sd_bus_set_watch_bind(sd_bus *bus, int b);
+int sd_bus_get_watch_bind(sd_bus *bus);
-int sd_bus_start(sd_bus *ret);
+int sd_bus_start(sd_bus *bus);
int sd_bus_try_close(sd_bus *bus);
void sd_bus_close(sd_bus *bus);