Yet another one of those useless-assert bugs:
Actually allow browsing for registration domains
git-svn-id: file:///home/lennart/svn/public/avahi/trunk@691
941a03a8-eaeb-0310-b9a0-
b1bbd8fe43fe
assert(server);
assert(callback);
- assert(type >= AVAHI_DOMAIN_BROWSER_BROWSE && type <= AVAHI_DOMAIN_BROWSER_BROWSE_LEGACY);
+
+ if (type >= AVAHI_DOMAIN_BROWSER_MAX) {
+ avahi_server_set_errno(server, AVAHI_ERR_INVALID_FLAGS);
+ return NULL;
+ }
if (!AVAHI_IF_VALID(interface)) {
avahi_server_set_errno(server, AVAHI_ERR_INVALID_INTERFACE);