summaryrefslogtreecommitdiffstats
path: root/avahi-compat-libdns_sd
diff options
context:
space:
mode:
Diffstat (limited to 'avahi-compat-libdns_sd')
-rw-r--r--avahi-compat-libdns_sd/compat.c16
-rw-r--r--avahi-compat-libdns_sd/warn.c2
2 files changed, 13 insertions, 5 deletions
diff --git a/avahi-compat-libdns_sd/compat.c b/avahi-compat-libdns_sd/compat.c
index a99e0f6..adca034 100644
--- a/avahi-compat-libdns_sd/compat.c
+++ b/avahi-compat-libdns_sd/compat.c
@@ -509,8 +509,10 @@ DNSServiceErrorType DNSSD_API DNSServiceBrowse(
assert(domain);
assert(callback);
- if (interface == kDNSServiceInterfaceIndexLocalOnly || flags != 0)
+ if (interface == kDNSServiceInterfaceIndexLocalOnly || flags != 0) {
+ AVAHI_WARN_UNSUPPORTED;
return kDNSServiceErr_Unsupported;
+ }
if (!(sdref = sdref_new()))
return kDNSServiceErr_Unknown;
@@ -625,8 +627,10 @@ DNSServiceErrorType DNSSD_API DNSServiceResolve(
assert(domain);
assert(callback);
- if (interface == kDNSServiceInterfaceIndexLocalOnly || flags != 0)
+ if (interface == kDNSServiceInterfaceIndexLocalOnly || flags != 0) {
+ AVAHI_WARN_UNSUPPORTED;
return kDNSServiceErr_Unsupported;
+ }
if (!(sdref = sdref_new()))
return kDNSServiceErr_Unknown;
@@ -739,8 +743,10 @@ DNSServiceErrorType DNSSD_API DNSServiceEnumerateDomains(
assert(callback);
if (interface == kDNSServiceInterfaceIndexLocalOnly ||
- (flags != kDNSServiceFlagsBrowseDomains && flags != kDNSServiceFlagsRegistrationDomains))
+ (flags != kDNSServiceFlagsBrowseDomains && flags != kDNSServiceFlagsRegistrationDomains)) {
+ AVAHI_WARN_UNSUPPORTED;
return kDNSServiceErr_Unsupported;
+ }
if (!(sdref = sdref_new()))
return kDNSServiceErr_Unknown;
@@ -952,8 +958,10 @@ DNSServiceErrorType DNSSD_API DNSServiceRegister (
assert(callback);
assert(regtype);
- if (interface == kDNSServiceInterfaceIndexLocalOnly || flags)
+ if (interface == kDNSServiceInterfaceIndexLocalOnly || flags) {
+ AVAHI_WARN_UNSUPPORTED;
return kDNSServiceErr_Unsupported;
+ }
if (!(sdref = sdref_new()))
return kDNSServiceErr_Unknown;
diff --git a/avahi-compat-libdns_sd/warn.c b/avahi-compat-libdns_sd/warn.c
index 859cfb0..7ebc7b1 100644
--- a/avahi-compat-libdns_sd/warn.c
+++ b/avahi-compat-libdns_sd/warn.c
@@ -78,7 +78,7 @@ void avahi_warn_unsupported(const char *function) {
char exename[256];
get_exe_name(exename, sizeof(exename));
- fprintf(stderr, "*** WARNING: The application '%s' called '%s()' which is not supported in the Bonjour compatiblity layer of Avahi. Please fix it to use the native API! ***\n", exename, function);
+ fprintf(stderr, "*** WARNING: The application '%s' called '%s()' which is not supported (or only supported partially) in the Bonjour compatiblity layer of Avahi. Please fix it to use the native API! ***\n", exename, function);
}