From 5101a6a10a265d5619264181ab2a67cfa7fb5099 Mon Sep 17 00:00:00 2001 From: Marcel Waldvogel Date: Sun, 24 Jun 2018 12:44:21 +0200 Subject: _listen_fd_with_names documentation now modeled after is_socket_sockaddr --- systemd/_daemon.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/systemd/_daemon.c b/systemd/_daemon.c index 9119f57..f48b84a 100644 --- a/systemd/_daemon.c +++ b/systemd/_daemon.c @@ -210,10 +210,13 @@ static PyObject* listen_fds(PyObject *self, PyObject *args, PyObject *keywds) { PyDoc_STRVAR(listen_fds_with_names__doc__, "_listen_fds_with_names(unset_environment=True) -> (int, str...)\n\n" + "Wraps sd_listen_fds_with_names(3).\n" +#ifdef HAVE_SD_LISTEN_FDS_WITH_NAMES "Return the number of descriptors passed to this process by the init system\n" "and their names as part of the socket-based activation logic.\n" - "Wraps sd_listen_fds_with_names(3).\n" - "Raises RunTimeError if compiled under systemd < 227." +#else + "NOT SUPPORTED: compiled without support sd_listen_fds_with_names" +#endif ); static void free_names(char **names) { -- cgit v1.2.1