diff options
author | Mikhail Zabaluev <mikhail.zabaluev@nokia.com> | 2011-11-07 19:45:37 +0200 |
---|---|---|
committer | Mikhail Zabaluev <mikhail.zabaluev@nokia.com> | 2011-11-07 19:45:37 +0200 |
commit | d4b62eeb7fd8c586ef5ffed19af098e043736d43 (patch) | |
tree | 7619637365d63bba8fb489013db0e3c39a9afabb | |
parent | 4de1cf73eaa89f75e540387be8c57e8fc34b343d (diff) |
TpSimplePasswordManager: don't keep a pointer to the challenge resultfix-password-manager
The pointer goes stale when the result is consumed,
and it trips an assertion if the manager gets a new challenge.
-rw-r--r-- | telepathy-glib/simple-password-manager.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/telepathy-glib/simple-password-manager.c b/telepathy-glib/simple-password-manager.c index 82d25445..cdb75b8d 100644 --- a/telepathy-glib/simple-password-manager.c +++ b/telepathy-glib/simple-password-manager.c @@ -99,7 +99,6 @@ struct _TpSimplePasswordManagerPrivate guint status_changed_id; TpBasePasswordChannel *channel; - GAsyncResult *result; gboolean dispose_has_run; }; @@ -344,16 +343,14 @@ tp_simple_password_manager_prompt_common_async ( g_return_if_fail (channel != NULL); g_return_if_fail (TP_IS_SIMPLE_PASSWORD_MANAGER (self)); g_return_if_fail (priv->channel == NULL); - g_return_if_fail (priv->result == NULL); priv->channel = g_object_ref (channel); - priv->result = g_object_ref (result); tp_g_signal_connect_object (priv->channel, "closed", G_CALLBACK (tp_simple_password_manager_channel_closed_cb), self, 0); tp_g_signal_connect_object (priv->channel, "finished", G_CALLBACK (tp_simple_password_manager_channel_finished_cb), - priv->result, 0); + g_object_ref (result), 0); tp_base_channel_register ((TpBaseChannel *) priv->channel); |