chiark / gitweb /
systemd-python: fix booted() and add two functions to docs
[elogind.git] / src / python-systemd / _daemon.c
index 6b84fb81c71b774c749c3ca91ed92e3f793286b3..f0ab16f659e2367f87057da2886ab1860a51084a 100644 (file)
@@ -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);