aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libempathy-gtk/empathy-password-dialog.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-password-dialog.c b/libempathy-gtk/empathy-password-dialog.c
index 5608bb035..442396de0 100644
--- a/libempathy-gtk/empathy-password-dialog.c
+++ b/libempathy-gtk/empathy-password-dialog.c
@@ -203,6 +203,13 @@ password_dialog_window_state_changed (GtkWidget *widget,
}
static void
+password_dialog_handler_invalidated_cb (EmpathyServerSASLHandler *handler,
+ EmpathyPasswordDialog *dialog)
+{
+ gtk_widget_destroy (GTK_WIDGET (dialog));
+}
+
+static void
empathy_password_dialog_constructed (GObject *object)
{
EmpathyPasswordDialog *dialog;
@@ -221,6 +228,10 @@ empathy_password_dialog_constructed (GObject *object)
account = empathy_server_sasl_handler_get_account (priv->handler);
+ tp_g_signal_connect_object (priv->handler, "invalidated",
+ G_CALLBACK (password_dialog_handler_invalidated_cb),
+ object, 0);
+
/* dialog */
gtk_dialog_add_buttons (GTK_DIALOG (dialog),
GTK_STOCK_OK, GTK_RESPONSE_OK,