summaryrefslogtreecommitdiffstats
path: root/avahi-daemon
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2007-01-06 16:16:41 +0000
committerLennart Poettering <lennart@poettering.net>2007-01-06 16:16:41 +0000
commit78567b1a41841a5fe341dba81c5656d95d909399 (patch)
tree6ded9fcb20960bab33cceff8a4367ddf14618d03 /avahi-daemon
parent81abdde5ccc144c160791bdfca1c9e2cadeef2e5 (diff)
fix a bogus error condition
git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1372 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
Diffstat (limited to 'avahi-daemon')
-rw-r--r--avahi-daemon/static-hosts.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/avahi-daemon/static-hosts.c b/avahi-daemon/static-hosts.c
index 35058fc..ebc358d 100644
--- a/avahi-daemon/static-hosts.c
+++ b/avahi-daemon/static-hosts.c
@@ -116,7 +116,7 @@ static void add_static_host_to_server(StaticHost *h)
if (!h->group)
if (!(h->group = avahi_s_entry_group_new (avahi_server, entry_group_callback, h))) {
- avahi_log_error("avahi_s_entry_group_new() failed: %s", avahi_strerror(err));
+ avahi_log_error("avahi_s_entry_group_new() failed: %s", avahi_strerror(avahi_server_errno(avahi_server)));
return;
}
@@ -130,7 +130,7 @@ static void add_static_host_to_server(StaticHost *h)
p = (a.proto == AVAHI_PROTO_INET && config->publish_a_on_ipv6) ||
(a.proto == AVAHI_PROTO_INET6 && config->publish_aaaa_on_ipv4) ? AVAHI_PROTO_UNSPEC : a.proto;
- if ((err = avahi_server_add_address(avahi_server, h->group, AVAHI_IF_UNSPEC, p, 0, h->host, &a))) {
+ if ((err = avahi_server_add_address(avahi_server, h->group, AVAHI_IF_UNSPEC, p, 0, h->host, &a)) < 0) {
avahi_log_error ("Static host name %s: avahi_server_add_address failure: %s", h->host, avahi_strerror(err));
return;
}