Mercurial > pidgin
diff libpurple/protocols/bonjour/mdns_avahi.c @ 32672:3828a61c44da
A boring and large patch so I can merge heads.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Fri, 23 Dec 2011 08:21:58 +0000 |
parents | 9c8b28dc6656 |
children |
line wrap: on
line diff
--- a/libpurple/protocols/bonjour/mdns_avahi.c Mon Aug 22 22:46:08 2011 +0000 +++ b/libpurple/protocols/bonjour/mdns_avahi.c Fri Dec 23 08:21:58 2011 +0000 @@ -179,6 +179,9 @@ ip[0] = '\0'; avahi_address_snprint(ip, AVAHI_ADDRESS_STR_MAX, a); + if (protocol == AVAHI_PROTO_INET6) + append_iface_if_linklocal(ip, interface); + purple_debug_info("bonjour", "_resolve_callback - name:%s ip:%s prev_ip:%s\n", name, ip, rd->ip); @@ -190,7 +193,7 @@ } /* IPv6 goes at the front of the list and IPv4 at the end so that we "prefer" IPv6, if present */ if (protocol == AVAHI_PROTO_INET6) { - rd->ip = g_strdup_printf("%s%%%d", ip, interface); + rd->ip = g_strdup_printf("%s", ip); bb->ips = g_slist_prepend(bb->ips, (gchar *) rd->ip); } else { rd->ip = g_strdup(ip); @@ -615,7 +618,7 @@ void _mdns_retrieve_buddy_icon(BonjourBuddy* buddy) { PurpleConnection *conn = purple_account_get_connection(buddy->account); - BonjourData *bd = conn->proto_data; + BonjourData *bd = purple_connection_get_protocol_data(conn); AvahiSessionImplData *session_idata = bd->dns_sd_data->mdns_impl_data; AvahiBuddyImplData *idata = buddy->mdns_impl_data; gchar *name;