From: <the...@us...> - 2006-05-08 23:59:31
|
Revision: 16155 Author: thekingant Date: 2006-05-07 21:02:34 -0700 (Sun, 07 May 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16155&view=rev Log Message: ----------- js->writeh is unsigned, and "0" should be used instead of "-1" to mean "there is no watcher" Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-05-08 03:52:53 UTC (rev 16154) +++ trunk/src/protocols/jabber/jabber.c 2006-05-08 04:02:34 UTC (rev 16155) @@ -214,7 +214,7 @@ if (writelen == 0) { gaim_input_remove(js->writeh); - js->writeh = -1; + js->writeh = 0; return; } @@ -264,7 +264,7 @@ sasl_encode(js->sasl, &data[pos], towrite, &out, &olen); pos += towrite; - if (js->writeh != -1) + if (js->writeh > 0) ret = jabber_do_send(js, out, olen); else { ret = -1; @@ -276,7 +276,7 @@ else if (ret < olen) { if (ret < 0) ret = 0; - if (js->writeh == -1) + if (js->writeh == 0) js->writeh = gaim_input_add( js->gsc ? js->gsc->fd : js->fd, GAIM_INPUT_WRITE, @@ -292,7 +292,7 @@ if (len == -1) len = strlen(data); - if (js->writeh == -1) + if (js->writeh == 0) ret = jabber_do_send(js, data, len); else { ret = -1; @@ -304,7 +304,7 @@ else if (ret < len) { if (ret < 0) ret = 0; - if (js->writeh == -1) + if (js->writeh == 0) js->writeh = gaim_input_add( js->gsc ? js->gsc->fd : js->fd, GAIM_INPUT_WRITE, jabber_send_cb, js); @@ -514,7 +514,6 @@ js->user = jabber_id_new(gaim_account_get_username(account)); js->next_id = g_random_int(); js->write_buffer = gaim_circ_buffer_new(512); - js->writeh = -1; if(!js->user) { gaim_connection_error(gc, _("Invalid Jabber ID")); @@ -859,7 +858,6 @@ } js->write_buffer = gaim_circ_buffer_new(512); - js->writeh = -1; if(!js->user->resource) { char *me; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-06-06 00:50:52
|
Revision: 16223 Author: seanegan Date: 2006-06-05 17:50:46 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16223&view=rev Log Message: ----------- bug fix Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-06-05 23:16:19 UTC (rev 16222) +++ trunk/src/protocols/jabber/jabber.c 2006-06-06 00:50:46 UTC (rev 16223) @@ -1457,21 +1457,21 @@ if(xmlnode_get_child(packet, "aborted")) { js->gc->wants_to_die = TRUE; text = _("Authorization Aborted"); - } else if(xmlnode_get_child(error, "incorrect-encoding")) { + } else if(xmlnode_get_child(packet, "incorrect-encoding")) { text = _("Incorrect encoding in authorization"); - } else if(xmlnode_get_child(error, "invalid-authzid")) { + } else if(xmlnode_get_child(packet, "invalid-authzid")) { js->gc->wants_to_die = TRUE; text = _("Invalid authzid"); - } else if(xmlnode_get_child(error, "invalid-mechanism")) { + } else if(xmlnode_get_child(packet, "invalid-mechanism")) { js->gc->wants_to_die = TRUE; text = _("Invalid Authorization Mechanism"); - } else if(xmlnode_get_child(error, "mechanism-too-weak")) { + } else if(xmlnode_get_child(packet, "mechanism-too-weak")) { js->gc->wants_to_die = TRUE; text = _("Authorization mechanism too weak"); - } else if(xmlnode_get_child(error, "not-authorized")) { + } else if(xmlnode_get_child(packet, "not-authorized")) { js->gc->wants_to_die = TRUE; text = _("Not Authorized"); - } else if(xmlnode_get_child(error, "temporary-auth-failure")) { + } else if(xmlnode_get_child(packet, "temporary-auth-failure")) { text = _("Temporary Authentication Failure"); } else { js->gc->wants_to_die = TRUE; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-07-10 18:02:52
|
Revision: 16477 Author: seanegan Date: 2006-07-10 11:02:48 -0700 (Mon, 10 Jul 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16477&view=rev Log Message: ----------- This problem seems to exist on gnutls too; there's really no need ever to try to send data after getting forcably disconnected anyway. Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-07-10 06:59:51 UTC (rev 16476) +++ trunk/src/protocols/jabber/jabber.c 2006-07-10 18:02:48 UTC (rev 16477) @@ -919,15 +919,11 @@ { JabberStream *js = gc->proto_data; -/* This is for Adium. Gaim never uses OpenSSL, because of licensing issues, - * and our configure doesn't check for it. -- rlaager */ -#ifdef HAVE_OPENSSL /* If using OpenSSL, don't perform any actions on the ssl connection * if we were forcibly disconnected because it will crash. -- evands */ if (!gc->disconnect_timeout) -#endif - jabber_send_raw(js, "</stream:stream>", -1); + jabber_send_raw(js, "</stream:stream>", -1); if(js->gsc) { #ifdef HAVE_OPENSSL This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-07-10 18:08:16
|
Revision: 16478 Author: seanegan Date: 2006-07-10 11:08:11 -0700 (Mon, 10 Jul 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16478&view=rev Log Message: ----------- It would be wise to fix the comments Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-07-10 18:02:48 UTC (rev 16477) +++ trunk/src/protocols/jabber/jabber.c 2006-07-10 18:08:11 UTC (rev 16478) @@ -919,8 +919,9 @@ { JabberStream *js = gc->proto_data; - /* If using OpenSSL, don't perform any actions on the ssl connection - * if we were forcibly disconnected because it will crash. -- evands + /* Don't perform any actions on the ssl connection + * if we were forcibly disconnected because it will crash + * on some SSL backends. */ if (!gc->disconnect_timeout) jabber_send_raw(js, "</stream:stream>", -1); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ev...@us...> - 2006-08-07 19:23:46
|
Revision: 16666 Author: evands Date: 2006-08-07 12:23:42 -0700 (Mon, 07 Aug 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16666&view=rev Log Message: ----------- When not connecting with "Use TLS (if available)" enabled, it's still possible to reach the JABBER_STREAM_REINITIALIZING connection stage. This is step 4 of the 5-step non-SSL connection process. In this situation, jabber_recv_cb_ssl() won't be called, so the delayed reintialization via js_>reinit being TRUE never occurs. jabber_stream_init() is immediately called in that situation. This may cause the same problems when using libxml which js->reinit was introduced to fix in [16585]. I'm not using libxml, so I couldn't test that... if so, a check against js->reinit and a subsequent jabber_stream_init() call is needed somewhere in the connection path taken when not using SSL. Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-08-07 17:16:54 UTC (rev 16665) +++ trunk/src/protocols/jabber/jabber.c 2006-08-07 19:23:42 UTC (rev 16666) @@ -1011,8 +1011,13 @@ break; case JABBER_STREAM_REINITIALIZING: gaim_connection_update_progress(js->gc, _("Re-initializing Stream"), - 6, JABBER_CONNECT_STEPS); - js->reinit = TRUE; + (js->gsc ? 7 : 4), JABBER_CONNECT_STEPS); + if (js->gsc) { + /* The stream will be reinitialized later, in jabber_recv_cb_ssl() */ + js->reinit = TRUE; + } else { + jabber_stream_init(js); + } break; case JABBER_STREAM_CONNECTED: jabber_roster_request(js); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-08-11 02:40:35
|
Revision: 16699 Author: datallah Date: 2006-08-10 19:40:31 -0700 (Thu, 10 Aug 2006) ViewCVS: http://svn.sourceforge.net/gaim/?rev=16699&view=rev Log Message: ----------- Leak fix. Modified Paths: -------------- trunk/src/protocols/jabber/jabber.c Modified: trunk/src/protocols/jabber/jabber.c =================================================================== --- trunk/src/protocols/jabber/jabber.c 2006-08-11 02:20:18 UTC (rev 16698) +++ trunk/src/protocols/jabber/jabber.c 2006-08-11 02:40:31 UTC (rev 16699) @@ -841,6 +841,8 @@ _("Register New Jabber Account"), instructions, fields, _("Register"), G_CALLBACK(jabber_register_cb), _("Cancel"), G_CALLBACK(jabber_register_cancel_cb), js); + + g_free(instructions); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |