]> git.0d.be Git - empathy.git/commitdiff
server-sasl-handler: add more debugging and only call Close in Status_Succeeded
authorJonny Lamb <jonnylamb@gnome.org>
Wed, 15 Dec 2010 09:10:56 +0000 (09:10 +0000)
committerJonny Lamb <jonnylamb@gnome.org>
Wed, 15 Dec 2010 09:11:47 +0000 (09:11 +0000)
Calling Close() straight after AcceptSASL() should be fine, but it
crashed gabble on versions < 0.11.4. Waiting for State_Accepted is
fine though.

Signed-off-by: Jonny Lamb <jonnylamb@gnome.org>
libempathy/empathy-server-sasl-handler.c

index 749311d4b714e91452f7cfc125546bf7e3818483..3cfc86fa8f66404122ebd8116172b7b5b6a35c5c 100644 (file)
@@ -89,9 +89,13 @@ sasl_status_changed_cb (TpChannel *channel,
 
   if (status == TP_SASL_STATUS_SERVER_SUCCEEDED)
     {
+      DEBUG ("Calling AcceptSASL");
       tp_cli_channel_interface_sasl_authentication_call_accept_sasl (
           priv->channel, -1, NULL, NULL, NULL, NULL);
-
+    }
+  else if (status == TP_SASL_STATUS_SUCCEEDED)
+    {
+      DEBUG ("SASL succeeded, calling Close");
       tp_cli_channel_call_close (priv->channel, -1,
           NULL, NULL, NULL, NULL);
     }