]> git.meshlink.io Git - catta/blobdiff - avahi-daemon/dbus-service-browser.c
work around a limitation in Gentoo's DBUS build (which is compiled with --disable...
[catta] / avahi-daemon / dbus-service-browser.c
index dc10b814a197c25e404ee34ac730fb71c74f0621..29d79b6d4372b55416d12c8f607c424d5bf3acd3 100644 (file)
@@ -38,8 +38,12 @@ void avahi_dbus_service_browser_free(ServiceBrowserInfo *i) {
 
     if (i->service_browser)
         avahi_s_service_browser_free(i->service_browser);
-    dbus_connection_unregister_object_path(server->bus, i->path);
-    avahi_free(i->path);
+
+    if (i->path) {
+        dbus_connection_unregister_object_path(server->bus, i->path);
+        avahi_free(i->path);
+    }
+    
     AVAHI_LLIST_REMOVE(ServiceBrowserInfo, service_browsers, i->client->service_browsers, i);
 
     i->client->n_objects--;
@@ -65,7 +69,7 @@ DBusHandlerResult avahi_dbus_msg_service_browser_impl(DBusConnection *c, DBusMes
 
     /* Introspection */
     if (dbus_message_is_method_call(m, DBUS_INTERFACE_INTROSPECTABLE, "Introspect"))
-        return avahi_dbus_handle_introspect(c, m, "ServiceBrowser.Introspect");
+        return avahi_dbus_handle_introspect(c, m, "ServiceBrowser.introspect");
     
     /* Access control */
     if (strcmp(dbus_message_get_sender(m), i->client->name))