# HG changeset patch # User Paul Aurich # Date 1308550058 0 # Node ID 835ea8811734c853c2dc8756e0944cf96f676a36 # Parent 5166e76265aeb8f285542ebb0e5bb3bd54db11c5# Parent 7eeaf38e27b0411beb1ce2e766d92abee8a32ebc merge of '3dbc4e50c575de418e1df8f965957b195aeff2ca' and '8e560053e153f10e0b7a2d211f7c20fbe7a2328d' diff -r 5166e76265ae -r 835ea8811734 libpurple/account.c --- a/libpurple/account.c Mon Jun 20 05:53:59 2011 +0000 +++ b/libpurple/account.c Mon Jun 20 06:07:38 2011 +0000 @@ -3038,19 +3038,19 @@ g_return_val_if_fail(name != NULL, NULL); g_return_val_if_fail(protocol_id != NULL, NULL); - who = g_strdup(purple_normalize(account, name)); for (l = purple_accounts_get_all(); l != NULL; l = l->next) { account = (PurpleAccount *)l->data; if (!purple_strequal(account->protocol_id, protocol_id)) continue; + who = g_strdup(purple_normalize(account, name)); if (purple_strequal(purple_normalize(account, purple_account_get_username(account)), who)) { g_free(who); return account; } + g_free(who); } - g_free(who); return NULL; }