Quoting a mail form JP Roseavear:
Attached is a patch to improve mDNSResponder compatability. For
DNSServiceBrowse and DNSServiceBrowser the apple lib returns an error if
ret_sdref is NULL and always guarantees the ret_sdref does not return
garbage (worst case it sets it to NULL). Apps definitely rely on the
latter, see https://bugzilla.novell.com/show_bug.cgi?id=213891 for
gphoto2 at least. Registering a service with an empty regtype should
also fail gracefully.
I remove the callback assert because apple allows that as well (maybe
not so good for avahi?)