]> git.meshlink.io Git - catta/blobdiff - avahi-daemon/dbus-protocol.c
Do not fail if address cannot be parsed - it is probably AVAHI_LOOKUP_NO_ADDRESS...
[catta] / avahi-daemon / dbus-protocol.c
index 25a9e8ebb96321e77f636788205cd7c36c49441e..ce2152179525729973add5aa6de334cc01f6065a 100644 (file)
@@ -1558,15 +1558,20 @@ static void async_service_resolver_callback(
 
 /*         avahi_log_debug(__FILE__": [%s] Successfully resolved service <%s.%s.%s>", i->path, name, type, domain); */
         
-        assert(a);
-        avahi_address_snprint(t, sizeof(t), a);
+        if (a)
+            avahi_address_snprint(t, sizeof(t), a);
+        else
+            t[0] = 0;
 
         if (!name)
             name = "";
 
         i_interface = (int32_t) interface;
         i_protocol = (int32_t) protocol;
-        i_aprotocol = (int32_t) a->proto;
+        if (a) 
+           i_aprotocol = (int32_t) a->proto;
+       else 
+           i_aprotocol = AVAHI_PROTO_UNSPEC;
         u_flags = (uint32_t) flags;
 
         dbus_message_append_args(