im.pidgin.pidgin.2.3.1: 0229267a6b0bd1415dceb56ad0ce2d51d59541a9

nosnilmot at pidgin.im nosnilmot at pidgin.im
Wed Dec 5 20:35:55 EST 2007


-----------------------------------------------------------------
Revision: 0229267a6b0bd1415dceb56ad0ce2d51d59541a9
Ancestor: 7127613288949841d5157be8e2b8a3553d53a8fc
Author: nosnilmot at pidgin.im
Date: 2007-12-06T01:17:36
Branch: im.pidgin.pidgin.2.3.1

Modified files:
        ChangeLog libpurple/protocols/irc/irc.c
        libpurple/protocols/irc/irc.h libpurple/protocols/irc/msgs.c

ChangeLog: 

applied changes from 5dc4cf40c038206bcf06fe7407e1e308b0264e32
             through 1d6b24ed027c253dbe63f69d5e40b43cd7faf436
Do not allow ISON requests to stack in IRC

-------------- next part --------------
============================================================
--- ChangeLog	51c9f134ea1f696bb1dd19f78aeac8274198ed1a
+++ ChangeLog	f30f4ebd8913ecf0d74f4744b38a320824e486fb
@@ -17,6 +17,8 @@ version 2.3.1 (12/??/2007):
 	* Don't advertise IPv6 on Bonjour because we don't support it
 	* Compile fixes for FreeBSD and Solaris
 	* Update QQ client version so we can connect again
+	* Do not allow ISON requests to stack in IRC, preventing flooding IRC
+	  servers when temporary network outages are restored
 
 
 version 2.3.0 (11/24/2007):
============================================================
--- libpurple/protocols/irc/irc.c	86a76691fd3b5732f3b8ee2fb2225ed840852304
+++ libpurple/protocols/irc/irc.c	a54326ee583fcd7b7cfe461cc96eff8003dc50f3
@@ -184,9 +184,14 @@ gboolean irc_blist_timeout(struct irc_co
 /* XXX I don't like messing directly with these buddies */
 gboolean irc_blist_timeout(struct irc_conn *irc)
 {
-	GString *string = g_string_sized_new(512);
+	GString *string;
 	char *list, *buf;
 
+	if (irc->ison_outstanding)
+		return TRUE;
+
+	string = g_string_sized_new(512);
+
 	g_hash_table_foreach(irc->buddies, (GHFunc)irc_buddy_append, (gpointer)string);
 
 	list = g_string_free(string, FALSE);
@@ -200,6 +205,8 @@ gboolean irc_blist_timeout(struct irc_co
 	irc_send(irc, buf);
 	g_free(buf);
 
+	irc->ison_outstanding = TRUE;
+
 	return TRUE;
 }
 
============================================================
--- libpurple/protocols/irc/irc.h	902fb8f09c5da6aaf12d0bfe6bd0db208dcdd93a
+++ libpurple/protocols/irc/irc.h	49082663654368df5b303822ac5bc8627e3bcd05
@@ -56,6 +56,8 @@ struct irc_conn {
 	guint timer;
 	GHashTable *buddies;
 
+	gboolean ison_outstanding;
+
 	char *inbuf;
 	int inbuflen;
 	int inbufused;
============================================================
--- libpurple/protocols/irc/msgs.c	64329da89fff1ffa6fa21a88acea88d319beb88f
+++ libpurple/protocols/irc/msgs.c	37fdc7040037099b9ca7ec8d1017b3426caccbd6
@@ -707,6 +707,7 @@ void irc_msg_ison(struct irc_conn *irc, 
 	g_strfreev(nicks);
 
 	g_hash_table_foreach(irc->buddies, (GHFunc)irc_buddy_status, (gpointer)irc);
+	irc->ison_outstanding = FALSE;
 }
 
 static void irc_buddy_status(char *name, struct irc_buddy *ib, struct irc_conn *irc)


More information about the Commits mailing list