diff libpurple/protocols/msn/msn.c @ 29049:23f6f80f45ed

Due to a server change, the friendly name on MSN was being changed to the first name of the user as supplied in their Address Book. Cache friendly names and use that at login, with a fallback to the AB name when none has been set. Fixes #10763.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Sat, 28 Nov 2009 23:13:55 +0000
parents f1437342cc0e
children 5c77b620375c 5259ca10b641 dd430f788bdc
line wrap: on
line diff
--- a/libpurple/protocols/msn/msn.c	Sat Nov 28 21:33:06 2009 +0000
+++ b/libpurple/protocols/msn/msn.c	Sat Nov 28 23:13:55 2009 +0000
@@ -1062,6 +1062,9 @@
 	if (strcmp(username, purple_account_get_username(account)))
 		purple_account_set_username(account, username);
 
+	username = purple_account_get_string(account, "display-name", NULL);
+	purple_connection_set_display_name(gc, username);
+
 	if (!msn_session_connect(session, host, port, http_method))
 		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,