empathy r1226 - trunk/libempathy-gtk
- From: xclaesse svn gnome org
- To: svn-commits-list gnome org
- Subject: empathy r1226 - trunk/libempathy-gtk
- Date: Mon, 14 Jul 2008 08:18:46 +0000 (UTC)
Author: xclaesse
Date: Mon Jul 14 08:18:46 2008
New Revision: 1226
URL: http://svn.gnome.org/viewvc/empathy?rev=1226&view=rev
Log:
Fix leaked accounts. mc_accounts_list ref all accounts.
Modified:
trunk/libempathy-gtk/empathy-accounts-dialog.c
Modified: trunk/libempathy-gtk/empathy-accounts-dialog.c
==============================================================================
--- trunk/libempathy-gtk/empathy-accounts-dialog.c (original)
+++ trunk/libempathy-gtk/empathy-accounts-dialog.c Mon Jul 14 08:18:46 2008
@@ -174,6 +174,7 @@
name = mc_account_get_display_name (account);
if (!name) {
+ g_object_unref (account);
continue;
}
@@ -765,17 +766,19 @@
g_object_unref (account);
/* Check if there is still accounts in CONNECTING state */
- accounts = mc_accounts_list ();
+ accounts = mc_accounts_list_by_enabled (TRUE);
for (l = accounts; l; l = l->next) {
- McAccount *this_account;
+ McAccount *this_account = l->data;
TpConnectionStatus status;
- this_account = l->data;
+ if (found) {
+ g_object_unref (this_account);
+ continue;
+ }
status = mission_control_get_connection_status (mc, this_account, NULL);
if (status == TP_CONNECTION_STATUS_CONNECTING) {
found = TRUE;
- break;
}
g_object_unref (this_account);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]