summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-11-11 19:53:59 -0500
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2015-07-05 14:19:21 -0400
commit07c1d9a144e492c13ef225f0b928d1edb8bf856c (patch)
treed3976748f3330b7d35b3768db1310a7d31f2b9c7
parent7bb40a26e0a228b0a6ad4871661838a8facd7eb5 (diff)
downloadpython-systemd-07c1d9a144e492c13ef225f0b928d1edb8bf856c.tar.gz
systemd-python: fix booted() and add two functions to docs
For some reason sphinx doesn't want to show inherited C functions.
-rw-r--r--systemd/_daemon.c2
-rw-r--r--systemd/docs/daemon.rst2
2 files changed, 3 insertions, 1 deletions
diff --git a/systemd/_daemon.c b/systemd/_daemon.c
index 6b84fb8..f0ab16f 100644
--- a/systemd/_daemon.c
+++ b/systemd/_daemon.c
@@ -51,7 +51,7 @@ static PyObject* booted(PyObject *self, PyObject *args) {
assert(args == NULL);
r = sd_booted();
- if (set_error(r, NULL, NULL))
+ if (set_error(r, NULL, NULL) < 0)
return NULL;
return PyBool_FromLong(r);
diff --git a/systemd/docs/daemon.rst b/systemd/docs/daemon.rst
index 72280ca..0ad11ed 100644
--- a/systemd/docs/daemon.rst
+++ b/systemd/docs/daemon.rst
@@ -14,3 +14,5 @@
.. autofunction:: _is_socket_unix
.. autofunction:: _is_socket_inet
.. autofunction:: _is_mq
+ .. autofunction:: notify
+ .. autofunction:: booted