summaryrefslogtreecommitdiffstats
path: root/avahi-daemon/main.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2006-01-20 22:56:11 +0000
committerLennart Poettering <lennart@poettering.net>2006-01-20 22:56:11 +0000
commite614891d38cae63957d0bfc00d34ecdbad4f8322 (patch)
tree55336f0efd0999e0ed17bec823470844587fe65c /avahi-daemon/main.c
parent7d59b3ba820c19488b0637b5dd9798deb68fb0dc (diff)
* add new API function avahi_nss_support()
* add new DBUS method Server.IsNSSSupportAvailable() * add support for IsNSSSupportAvailabke() to avahi-bookmarks git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1092 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
Diffstat (limited to 'avahi-daemon/main.c')
-rw-r--r--avahi-daemon/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/avahi-daemon/main.c b/avahi-daemon/main.c
index da19868..8327200 100644
--- a/avahi-daemon/main.c
+++ b/avahi-daemon/main.c
@@ -75,6 +75,7 @@
AvahiServer *avahi_server = NULL;
AvahiSimplePoll *simple_poll_api = NULL;
static char *argv0 = NULL;
+int nss_support = 0;
typedef enum {
DAEMON_RUN,
@@ -697,6 +698,8 @@ static void signal_callback(AvahiWatch *watch, AVAHI_GCC_UNUSED int fd, AVAHI_GC
}
}
+/* Imported from ../avahi-client/nss-check.c */
+int avahi_nss_support(void);
static int run_server(DaemonConfig *c) {
int r = -1;
@@ -707,6 +710,9 @@ static int run_server(DaemonConfig *c) {
assert(c);
+ if (!(nss_support = avahi_nss_support()))
+ avahi_log_warn("WARNING: No NSS support for mDNS detected, consider installing nss-mdns!");
+
if (!(simple_poll_api = avahi_simple_poll_new())) {
avahi_log_error("Failed to create main loop object.");
goto finish;