From: msweet Date: Fri, 21 Mar 2014 18:28:30 +0000 (+0000) Subject: Fix systemd build on Linux. X-Git-Tag: v2.2b1~702 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=5950e7bd5ef3be09c9c6b69fbff87dba39a6f41a;p=thirdparty%2Fcups.git Fix systemd build on Linux. git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@11722 a1ca3aef-8c08-0410-bb20-df032aa958be --- diff --git a/scheduler/main.c b/scheduler/main.c index cb7d4e301..132cc6060 100644 --- a/scheduler/main.c +++ b/scheduler/main.c @@ -35,6 +35,7 @@ extern int launch_activate_socket(const char *name, int **fds, size_t *cnt); #endif /* HAVE_LAUNCH_H */ #ifdef HAVE_SYSTEMD +# include # define CUPS_KEEPALIVE CUPS_CACHEDIR "/org.cups.cupsd" /* Name of the systemd path file */ #endif /* HAVE_SYSTEMD */ @@ -2042,7 +2043,7 @@ service_checkin(void) if ((count = sd_listen_fds(0)) < 0) { - cupsdLogMessage(CUPSD_LOG_ERROR, "service_checkin: Unable to get listener sockets: %s", strerror(error)); + cupsdLogMessage(CUPSD_LOG_ERROR, "service_checkin: Unable to get listener sockets: %s", strerror(-count)); exit(EXIT_FAILURE); return; /* anti-compiler-warning */ }