aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk/empathy-account-chooser.c
diff options
context:
space:
mode:
authorWill Thompson <will.thompson@collabora.co.uk>2011-09-09 22:28:42 +0800
committerWill Thompson <will.thompson@collabora.co.uk>2011-09-13 21:17:57 +0800
commit0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722 (patch)
tree8fc22859e7cc03980cb4537a7ff0f0c225c8fda1 /libempathy-gtk/empathy-account-chooser.c
parent80a217a0b8533f8f936140082b90da793bc1b154 (diff)
downloadgsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar.gz
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar.bz2
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar.lz
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar.xz
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.tar.zst
gsoc2013-empathy-0a3f996d2ec2eed860edda7c36a9b6bdbd9d2722.zip
AccountChooser: don't return garbage from _set_account
Previously, the 'set' field of the stack-allocated 'data' structure was not initialized. It's explicitly set to TRUE if the account is found, but never otherwise set; so if the account is not found, this function returned random garbage. Reviewed-by: Xavier Claessens <xclaesse@gmail.com>
Diffstat (limited to 'libempathy-gtk/empathy-account-chooser.c')
-rw-r--r--libempathy-gtk/empathy-account-chooser.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-account-chooser.c b/libempathy-gtk/empathy-account-chooser.c
index cb9028c31..c16f9c7e2 100644
--- a/libempathy-gtk/empathy-account-chooser.c
+++ b/libempathy-gtk/empathy-account-chooser.c
@@ -428,6 +428,7 @@ empathy_account_chooser_set_account (EmpathyAccountChooser *chooser,
data.chooser = chooser;
data.account = account;
+ data.set = FALSE;
gtk_tree_model_foreach (model,
(GtkTreeModelForeachFunc) account_chooser_set_account_foreach,