diff options
Diffstat (limited to 'libempathy-gtk')
-rw-r--r-- | libempathy-gtk/empathy-account-chooser.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-account-chooser.c b/libempathy-gtk/empathy-account-chooser.c index 8256707c0..7624c2c13 100644 --- a/libempathy-gtk/empathy-account-chooser.c +++ b/libempathy-gtk/empathy-account-chooser.c @@ -303,6 +303,14 @@ empathy_account_chooser_get_connection (EmpathyAccountChooser *chooser) priv = GET_PRIV (chooser); account = empathy_account_chooser_dup_account (chooser); + + /* if the returned account is NULL, then the account manager probably + * hasn't been prepared yet. It should be safe to return NULL here + * though. */ + if (account == NULL) { + return NULL; + } + connection = tp_account_get_connection (account); g_object_unref (account); |