summaryrefslogtreecommitdiffstats
path: root/avahi-core
diff options
context:
space:
mode:
Diffstat (limited to 'avahi-core')
-rw-r--r--avahi-core/server.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/avahi-core/server.c b/avahi-core/server.c
index 6ba8ea0..235247a 100644
--- a/avahi-core/server.c
+++ b/avahi-core/server.c
@@ -1472,15 +1472,14 @@ static int check_record_conflict(AvahiServer *s, AvahiIfIndex interface, AvahiPr
if ((flags & AVAHI_ENTRY_ALLOWMUTIPLE) && (e->flags & AVAHI_ENTRY_ALLOWMUTIPLE) )
continue;
- if (interface <= 0 ||
- e->interface <= 0 ||
- e->interface == interface ||
- protocol == AVAHI_PROTO_UNSPEC ||
- e->protocol == AVAHI_PROTO_UNSPEC ||
- e->protocol == protocol)
+ if ((interface <= 0 ||
+ e->interface <= 0 ||
+ e->interface == interface) &&
+ (protocol == AVAHI_PROTO_UNSPEC ||
+ e->protocol == AVAHI_PROTO_UNSPEC ||
+ e->protocol == protocol))
return -1;
-
}
return 0;