diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2021-04-08 14:59:10 +0200 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2021-04-08 14:59:10 +0200 |
commit | 3bbb76f62123f59ad871bebd00fdcd3f0c974275 (patch) | |
tree | 6a6d220f98d539fb73074be0207e3d9a6ef0f0c1 /man | |
parent | network: do not emit changed properties when bus connection is not ready (diff) | |
download | systemd-3bbb76f62123f59ad871bebd00fdcd3f0c974275.tar.xz systemd-3bbb76f62123f59ad871bebd00fdcd3f0c974275.zip |
sd-bus: make sd_bus_is_{ready,open} accept NULL
We didn't document this behaviour one way or another, so I think it's
OK to change. All callers do the NULL check before callling this to avoid
the assert warning, so it seems reasonable to do it internally.
sd_bus_can_send() is similar, but there we expressly say that an
error is returned on NULL, so I didn't change it.
Diffstat (limited to 'man')
-rw-r--r-- | man/sd_bus_is_open.xml | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/man/sd_bus_is_open.xml b/man/sd_bus_is_open.xml index 8e0aed29b3..621ed272bb 100644 --- a/man/sd_bus_is_open.xml +++ b/man/sd_bus_is_open.xml @@ -57,6 +57,9 @@ zero outside of this state, and positive otherwise. Effectively, this function returns positive while regular messages can be sent or received on the connection.</para> + <para>The <parameter>bus</parameter> argument may be <constant>NULL</constant>, zero is also returned in + that case.</para> + <para>To be notified when the connection is fully established, use <citerefentry><refentrytitle>sd_bus_set_connected_signal</refentrytitle><manvolnum>3</manvolnum></citerefentry> and install a match for the <function>Connected()</function> signal on the @@ -68,8 +71,8 @@ <refsect1> <title>Return Value</title> - <para>On success, these functions return 0 or a positive integer. On failure, they return a negative errno-style - error code.</para> + <para>Those functions return 0 if the bus is <emphasis>not</emphasis> in the given state, and a positive + integer when it is. On failure, a negative errno-style error code is returned.</para> <refsect2> <title>Errors</title> |