telepathy-mission-control: mc-tool: use tp_account_manager_dup_valid_accounts
Simon McVittie
smcv at kemper.freedesktop.org
Mon Oct 8 07:27:45 PDT 2012
Module: telepathy-mission-control
Branch: master
Commit: 8310376a77d8a591d438dd65f5050081430bd5ff
URL: http://cgit.freedesktop.org/telepathy/telepathy-mission-control/commit/?id=8310376a77d8a591d438dd65f5050081430bd5ff
Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date: Fri Sep 14 13:30:00 2012 +0100
mc-tool: use tp_account_manager_dup_valid_accounts
tp_account_manager_get_valid_accounts has the confusing
(transfer container) transfer-mode, and is deprecated in telepathy-glib
0.19.9.
Signed-off-by: Simon McVittie <simon.mcvittie at collabora.co.uk>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=55391
Reviewed-by: Xavier Claessens <xavier.claessens at collabora.co.uk>
---
util/mc-tool.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/util/mc-tool.c b/util/mc-tool.c
index 98f56d1..9cf13d5 100644
--- a/util/mc-tool.c
+++ b/util/mc-tool.c
@@ -515,16 +515,16 @@ compare_accounts (gconstpointer a,
}
static GList *
-get_valid_accounts_sorted (TpAccountManager *manager)
+dup_valid_accounts_sorted (TpAccountManager *manager)
{
- return g_list_sort (tp_account_manager_get_valid_accounts (manager),
+ return g_list_sort (tp_account_manager_dup_valid_accounts (manager),
compare_accounts);
}
static gboolean
command_list (TpAccountManager *manager)
{
- GList *accounts = get_valid_accounts_sorted (manager);
+ GList *accounts = dup_valid_accounts_sorted (manager);
if (accounts != NULL) {
GList *ptr;
@@ -535,7 +535,7 @@ command_list (TpAccountManager *manager)
puts (tp_account_get_path_suffix (ptr->data));
}
- g_list_free (accounts);
+ g_list_free_full (accounts, g_object_unref);
}
return FALSE; /* stop mainloop */
@@ -547,7 +547,7 @@ command_summary (TpAccountManager *manager)
GList *accounts, *l;
guint longest_account = 0;
- accounts = tp_account_manager_get_valid_accounts (manager);
+ accounts = tp_account_manager_dup_valid_accounts (manager);
if (accounts == NULL) {
return FALSE;
}
@@ -580,7 +580,7 @@ command_summary (TpAccountManager *manager)
status);
}
- g_list_free (accounts);
+ g_list_free_full (accounts, g_object_unref);
return FALSE; /* stop mainloop */
}
@@ -822,7 +822,7 @@ command_dump (TpAccountManager *manager)
{
GList *accounts, *l;
- accounts = tp_account_manager_get_valid_accounts (manager);
+ accounts = tp_account_manager_dup_valid_accounts (manager);
if (accounts == NULL) {
return FALSE;
}
@@ -837,7 +837,7 @@ command_dump (TpAccountManager *manager)
printf ("\n------------------------------------------------------------\n\n");
}
- g_list_free (accounts);
+ g_list_free_full (accounts, g_object_unref);
return FALSE; /* stop mainloop */
}
More information about the telepathy-commits
mailing list