rpms/pidgin/F-11 pidgin-2.7.0-chatfilter.patch, NONE, 1.1 pidgin-2.7.0-icqhtml.patch, NONE, 1.1 pidgin-2.7.0-nulldref-592750.patch, NONE, 1.1 pidgin-2.7.0-oscarcrash.patch, NONE, 1.1 pidgin-2.7.0-trayblink-11855.patch, NONE, 1.1 pidgin-2.7.0-yahooraces.patch, NONE, 1.1 pidgin.spec, 1.84, 1.85

Stu Tomlinson nosnilmot at fedoraproject.org
Thu May 20 02:09:29 UTC 2010


Author: nosnilmot

Update of /cvs/extras/rpms/pidgin/F-11
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv20114/F-11

Modified Files:
	pidgin.spec 
Added Files:
	pidgin-2.7.0-chatfilter.patch pidgin-2.7.0-icqhtml.patch 
	pidgin-2.7.0-nulldref-592750.patch 
	pidgin-2.7.0-oscarcrash.patch 
	pidgin-2.7.0-trayblink-11855.patch 
	pidgin-2.7.0-yahooraces.patch 
Log Message:
Fix several issues backported from upstream:
  3c30f64efedafc379b6536852bbb3b6ef5f1f6c9 - fix for receiving HTML on ICQ
  13fbe0815f84d5b3c001947559f5818c10275f4c - prevent null deref on disconnecting account (#592750)
  c4a874926d07b8597db4b78a181a89cf720a8418 - fix blinking tray icon on new message (#592691)
  cfe0e649dda34d9252d40d8f67e445336a247998 - prevent race condition on Yahoo! login
  e3dd36706068f3b8eabd630ff71d270c145cce42 - fix crash in Oscar (#548128)
  13fbe0815f84d5b3c001947559f5818c10275f4c - fix crash during network disconnect (#592750)


pidgin-2.7.0-chatfilter.patch:
 gtkblist.c |    3 +++
 1 file changed, 3 insertions(+)

--- NEW FILE pidgin-2.7.0-chatfilter.patch ---
-----------------------------------------------------------------
Revision: 13fbe0815f84d5b3c001947559f5818c10275f4c
Ancestor: cfe0e649dda34d9252d40d8f67e445336a247998
Author: nosnilmot at pidgin.im
Date: 05/17/2010 01:11:01 AM
Branch: im.pidgin.pidgin

Modified files:
        pidgin/gtkblist.c

ChangeLog: 

Prevent a null pointer dereference in chat_account_filter_func() if called
on a disconnected or disconnecting account. 
This should fix https://bugzilla.redhat.com/show_bug.cgi?id=592750


============================================================
--- pidgin/gtkblist.c	59572bc5415328dec42852173febb8e6d216f911
+++ pidgin/gtkblist.c	cbe664829ff51113e1fda2ec2c6f1791a3b46c47
@@ -942,6 +942,9 @@ chat_account_filter_func(PurpleAccount *
 	PurpleConnection *gc = purple_account_get_connection(account);
 	PurplePluginProtocolInfo *prpl_info = NULL;
 
+	if (gc == NULL)
+		return FALSE;
+
 	prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl);
 
 	return (prpl_info->chat_info != NULL);

pidgin-2.7.0-icqhtml.patch:
 oscar.c |   29 ++---------------------------
 1 file changed, 2 insertions(+), 27 deletions(-)

--- NEW FILE pidgin-2.7.0-icqhtml.patch ---
Manually edited to make it compile
-----------------------------------------------------------------
Revision: 3c30f64efedafc379b6536852bbb3b6ef5f1f6c9
Ancestor: 0e263caa5d687101e436029f2f8d09053ae06e23
Author: ivan.komarov at soc.pidgin.im
Date: 05/03/2010 09:49:14 PM
Branch: im.pidgin.soc.2010.icq-tlc

Modified files:
        libpurple/protocols/oscar/oscar.c

ChangeLog: 

Two small fixes to improve sending/receiving HTML-formatted messages
over ICQ.
  * Treat all incoming messages as HTML because a) this is what the official
    client does and b) we don't have a reliable way to check if a message is
    HTML anyway.
  * Wrap outgoing HTML in proper HTML tags to make ICQ6 happy.
This was tested with ICQ 6/7, Miranda, Trillian, QIP, and iChat.

============================================================
--- libpurple/protocols/oscar/oscar.c	ec79d8d9fcba376be091b363977e8f23c748eff2
+++ libpurple/protocols/oscar/oscar.c	f60533d05cd497bf87168ca7e6f259539ce18fd8
@@ -2486,32 +2486,6 @@ static int incomingim_chan1(OscarData *o
 	tmp = g_string_free(message, FALSE);
 
 	/*
-	 * If the message is from an ICQ user and to an ICQ user then escape any HTML,
-	 * because HTML is not sent over ICQ as a means to format a message.
-	 * So any HTML we receive is intended to be displayed.  Also, \r\n must be
-	 * replaced with <br>
-	 *
-	 * Note: There *may* be some clients which send messages as HTML formatted -
-	 *       they need to be special-cased somehow.
-	 *
-	 * Update: Newer ICQ clients have started sending IMs as HTML.  We can
-	 * distinguish HTML IMs from non-HTML IMs by looking at the features.  If
-	 * the features are "0x 01 06" then the message is plain text.  If the
-	 * features are "0x 01" then the message is HTML.
-	 */
-	if (od->icq && oscar_util_valid_name_icq(userinfo->bn)
-			&& (args->featureslen != 1 || args->features[0] != 0x01))
-	{
-		/* being recevied by ICQ from ICQ - escape HTML so it is displayed as sent */
-		gchar *tmp2 = g_markup_escape_text(tmp, -1);
-		g_free(tmp);
-		tmp = tmp2;
-		tmp2 = purple_strreplace(tmp, "\r\n", "<br>");
-		g_free(tmp);
-		tmp = tmp2;
-	}
-
-	/*
 	 * Convert iChat color tags to normal font tags.
 	 */
 	if (purple_markup_find_tag("body", tmp, &start, &end, &attribs))
@@ -4787,7 +4761,8 @@ oscar_send_im(PurpleConnection *gc, cons
 			tmp2 = purple_markup_strip_html(tmp1);
 			is_html = FALSE;
 		} else {
-			tmp2 = g_strdup(tmp1);
+			/* ICQ 6 wants its HTML wrapped in these tags. Oblige it. */
+			tmp2 = g_strdup_printf("<HTML><BODY>%s</BODY></HTML>", tmp1);
 			is_html = TRUE;
 		}
 		g_free(tmp1);

pidgin-2.7.0-nulldref-592750.patch:
 gtkblist.c |    3 +++
 1 file changed, 3 insertions(+)

--- NEW FILE pidgin-2.7.0-nulldref-592750.patch ---
-----------------------------------------------------------------
Revision: 13fbe0815f84d5b3c001947559f5818c10275f4c
Ancestor: cfe0e649dda34d9252d40d8f67e445336a247998
Author: nosnilmot at pidgin.im
Date: 05/17/2010 01:11:01 AM
Branch: im.pidgin.pidgin

Modified files:
        pidgin/gtkblist.c

ChangeLog: 

Prevent a null pointer dereference in chat_account_filter_func() if called
on a disconnected or disconnecting account. 
This should fix https://bugzilla.redhat.com/show_bug.cgi?id=592750


============================================================
--- pidgin/gtkblist.c	59572bc5415328dec42852173febb8e6d216f911
+++ pidgin/gtkblist.c	cbe664829ff51113e1fda2ec2c6f1791a3b46c47
@@ -942,6 +942,9 @@ chat_account_filter_func(PurpleAccount *
 	PurpleConnection *gc = purple_account_get_connection(account);
 	PurplePluginProtocolInfo *prpl_info = NULL;
 
+	if (gc == NULL)
+		return FALSE;
+
 	prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl);
 
 	return (prpl_info->chat_info != NULL);

pidgin-2.7.0-oscarcrash.patch:
 family_icbm.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

--- NEW FILE pidgin-2.7.0-oscarcrash.patch ---
-----------------------------------------------------------------
Revision: e3dd36706068f3b8eabd630ff71d270c145cce42
Ancestor: 6c2368ad4315c5277c41916c2be642f8aa1894e2
Author: markdoliner at pidgin.im
Date: 05/20/2010 02:39:25 AM
Branch: im.pidgin.pidgin

Modified files:
        libpurple/protocols/oscar/family_icbm.c

ChangeLog: 

If we get an error SNAC on the ICBM family and it's missing buddy name then
don't fallthrough to the default error handler in misc.c.  This was causing
purple_parse_msgerr() in oscar.c to get called with different va_args than
it was expecting, which caused a crash.  Specifically when trying to fetch
the ICQ x-status of an offline buddy.

Fixes #11863.  This is nosnilmot's patch, I believe.  I had no part in it,
other than verifying that I do believe it'll fix the crash.

============================================================
--- libpurple/protocols/oscar/family_icbm.c	fcbebddf7bb56d37e2e89ffa10da1b73e63cf833
+++ libpurple/protocols/oscar/family_icbm.c	62126e23e6971a85d9b599c7ca61675a008e6f9b
@@ -166,20 +166,20 @@ error(OscarData *od, FlapConnection *con
 
 	if (!(snac2 = aim_remsnac(od, snac->id))) {
 		purple_debug_misc("oscar", "icbm error: received response from unknown request!\n");
-		return 0;
+		return 1;
 	}
 
 	if (snac2->family != SNAC_FAMILY_ICBM) {
 		purple_debug_misc("oscar", "icbm error: received response from invalid request! %d\n", snac2->family);
 		g_free(snac2->data);
 		g_free(snac2);
-		return 0;
+		return 1;
 	}
 
 	if (!(bn = snac2->data)) {
 		purple_debug_misc("oscar", "icbm error: received response from request without a buddy name!\n");
 		g_free(snac2);
-		return 0;
+		return 1;
 	}
 
 	reason = byte_stream_get16(bs);

pidgin-2.7.0-trayblink-11855.patch:
 gtkdocklet-gtk.c |    6 ++++++
 1 file changed, 6 insertions(+)

--- NEW FILE pidgin-2.7.0-trayblink-11855.patch ---
-----------------------------------------------------------------
Revision: c4a874926d07b8597db4b78a181a89cf720a8418
Ancestor: dcd1194eb2bd80a296737c518ce2474661d9fa1f
Author: darkrain42 at pidgin.im
Date: 05/16/2010 04:50:23 PM
Branch: im.pidgin.pidgin

Modified files:
        ChangeLog pidgin/gtkdocklet-gtk.c

ChangeLog: 

pidgin: Add charkins's patch for gtkstatusicon blinking.  Fixes #11855

============================================================
--- pidgin/gtkdocklet-gtk.c	621886961dfcbcd728e875983d4e131264731683
+++ pidgin/gtkdocklet-gtk.c	4c8694f749bba34ea1eda230978b1173e7353de6
@@ -75,6 +75,12 @@ docklet_gtk_status_update_icon(PurpleSta
 	if (icon_name) {
 		gtk_status_icon_set_from_icon_name(docklet, icon_name);
 	}
+
+	if (purple_prefs_get_bool(PIDGIN_PREFS_ROOT "/docklet/blink")) {
+		gtk_status_icon_set_blinking(docklet, (pending && !connecting));
+	} else if (gtk_status_icon_get_blinking(docklet)) {
+		gtk_status_icon_set_blinking(docklet, FALSE);
+	}
 }
 
 static void

pidgin-2.7.0-yahooraces.patch:
 libymsg.c |   41 +++++++++++++++++++++++------------------
 1 file changed, 23 insertions(+), 18 deletions(-)

--- NEW FILE pidgin-2.7.0-yahooraces.patch ---
-----------------------------------------------------------------
Revision: cfe0e649dda34d9252d40d8f67e445336a247998
Ancestor: c22043ed4b564d247db393d18a3de8df21981254
Author: darkrain42 at pidgin.im
Date: 05/16/2010 09:56:47 PM
Branch: im.pidgin.pidgin

Modified files:
        libpurple/protocols/yahoo/libymsg.c

ChangeLog: 

yahoo: Fix a few race-condition crashes at login

(if the account disconnects while these fetches are in-progress).

============================================================
--- libpurple/protocols/yahoo/libymsg.c	53134e145a6dee215c5559bd5a0478c93ddcb901
+++ libpurple/protocols/yahoo/libymsg.c	a78b9b5fa500695a7250aa0b14f0f20273471b2c
@@ -1787,23 +1787,17 @@ static gchar *yahoo_auth16_get_cookie_b(
 	return tmp2;
 }
 
-static void yahoo_auth16_stage2(PurpleUtilFetchUrlData *unused, gpointer user_data, const gchar *ret_data, size_t len, const gchar *error_message)
+static void yahoo_auth16_stage2(PurpleUtilFetchUrlData *url_data, gpointer user_data, const gchar *ret_data, size_t len, const gchar *error_message)
 {
 	struct yahoo_auth_data *auth_data = user_data;
 	PurpleConnection *gc = auth_data->gc;
-	YahooData *yd;
+	YahooData *yd = purple_connection_get_protocol_data(gc);
 	gboolean try_login_on_error = FALSE;
 
 	purple_debug_info("yahoo","Authentication: In yahoo_auth16_stage2\n");
 
-	if (!PURPLE_CONNECTION_IS_VALID(gc)) {
-		g_free(auth_data->seed);
-		g_free(auth_data);
-		g_return_if_reached();
-	}
-
-	yd = (YahooData *)gc->proto_data;
-
+	yd->url_datas = g_slist_remove(yd->url_datas, url_data);
+	
 	if (error_message != NULL) {
 		purple_debug_error("yahoo", "Login Failed, unable to retrieve stage 2 url: %s\n", error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, error_message);
@@ -1910,18 +1904,15 @@ static void yahoo_auth16_stage2(PurpleUt
 	g_free(auth_data);
 }
 
-static void yahoo_auth16_stage1_cb(PurpleUtilFetchUrlData *unused, gpointer user_data, const gchar *ret_data, size_t len, const gchar *error_message)
+static void yahoo_auth16_stage1_cb(PurpleUtilFetchUrlData *url_data, gpointer user_data, const gchar *ret_data, size_t len, const gchar *error_message)
 {
 	struct yahoo_auth_data *auth_data = user_data;
 	PurpleConnection *gc = auth_data->gc;
+	YahooData *yd = purple_connection_get_protocol_data(gc);
 
 	purple_debug_info("yahoo","Authentication: In yahoo_auth16_stage1_cb\n");
 
-	if (!PURPLE_CONNECTION_IS_VALID(gc)) {
-		g_free(auth_data->seed);
-		g_free(auth_data);
-		g_return_if_reached();
-	}
+	yd->url_datas = g_slist_remove(yd->url_datas, url_data);
 
 	if (error_message != NULL) {
 		purple_debug_error("yahoo", "Login Failed, unable to retrieve login url: %s\n", error_message);
@@ -2023,6 +2014,8 @@ static void yahoo_auth16_stage1_cb(Purpl
 			url_data = purple_util_fetch_url_request_len_with_account(
 					proxy_ssl ? account : NULL, url, TRUE, YAHOO_CLIENT_USERAGENT,
 					TRUE, NULL, TRUE, -1, yahoo_auth16_stage2, auth_data);
+			if (url_data)
+				yd->url_datas = g_slist_prepend(yd->url_datas, url_data);
 			g_free(url);
 			g_free(token);
 		}
@@ -2031,6 +2024,7 @@ static void yahoo_auth16_stage1(PurpleCo
 
 static void yahoo_auth16_stage1(PurpleConnection *gc, const char *seed)
 {
+	YahooData *yd = purple_connection_get_protocol_data(gc);
 	PurpleAccount *account = purple_connection_get_account(gc);
 	PurpleUtilFetchUrlData *url_data = NULL;
 	struct yahoo_auth_data *auth_data = NULL;
@@ -2062,6 +2056,8 @@ static void yahoo_auth16_stage1(PurpleCo
 			proxy_ssl ? account : NULL, url, TRUE,
 			YAHOO_CLIENT_USERAGENT, TRUE, NULL, FALSE, -1,
 			yahoo_auth16_stage1_cb, auth_data);
+	if (url_data)
+		yd->url_datas = g_slist_prepend(yd->url_datas, url_data);
 
 	g_free(url);
 }
@@ -3600,6 +3596,8 @@ static void yahoo_got_pager_server(Purpl
 	gchar **strings = NULL, *cs_server = NULL;
 	int port = 0, stringslen = 0;
 
+	yd->url_datas = g_slist_remove(yd->url_datas, url_data);
+
 	if(error_message != NULL || len == 0) {
 		purple_debug_error("yahoo", "Unable to retrieve server info. %"
 				G_GSIZE_FORMAT " bytes retrieved with error message: %s\n", len,
@@ -3646,6 +3644,7 @@ void yahoo_login(PurpleAccount *account)
 	YahooData *yd = gc->proto_data = g_new0(YahooData, 1);
 	PurpleStatus *status = purple_account_get_active_status(account);
 	gboolean use_whole_url = yahoo_account_use_http_proxy(gc);
+	PurpleUtilFetchUrlData *url_data;
 
 	gc->flags |= PURPLE_CONNECTION_HTML | PURPLE_CONNECTION_NO_BGCOLOR | PURPLE_CONNECTION_NO_URLDESC;
 
@@ -3678,12 +3677,14 @@ void yahoo_login(PurpleAccount *account)
 
 	/* Get the pager server.  Actually start connecting in the callback since we
 	 * must have the contents of the HTTP response to proceed. */
-	purple_util_fetch_url_request_len_with_account(
+	url_data = purple_util_fetch_url_request_len_with_account(
 			purple_connection_get_account(gc),
 			yd->jp ? YAHOOJP_PAGER_HOST_REQ_URL : YAHOO_PAGER_HOST_REQ_URL,
 			use_whole_url ? TRUE : FALSE,
 			YAHOO_CLIENT_USERAGENT, TRUE, NULL, FALSE, -1,
 			yahoo_got_pager_server, yd);
+	if (url_data)
+		yd->url_datas = g_slist_prepend(yd->url_datas, url_data);
 
 	return;
 }
@@ -4373,6 +4374,8 @@ static void yahoo_get_sms_carrier_cb(Pur
 	PurpleAccount *account = purple_connection_get_account(gc);
 	PurpleConversation *conv = purple_find_conversation_with_account(PURPLE_CONV_TYPE_IM, sms_cb_data->who, account);
 
+	yd->url_datas = g_slist_remove(yd->url_datas, url_data);
+
 	if (error_message != NULL) {
 		purple_conversation_write(conv, NULL, _("Can't send SMS. Unable to obtain mobile carrier."), PURPLE_MESSAGE_SYSTEM, time(NULL));
 
@@ -4466,7 +4469,9 @@ static void yahoo_get_sms_carrier(Purple
 	g_free(request);
 	g_free(validate_request_str);
 
-	if (!url_data) {
+	if (url_data)
+		yd->url_datas = g_slist_prepend(yd->url_datas, url_data);
+	else {
 		PurpleAccount *account = purple_connection_get_account(gc);
 		PurpleConversation *conv = purple_find_conversation_with_account(PURPLE_CONV_TYPE_IM, sms_cb_data->who, account);
 		purple_conversation_write(conv, NULL, _("Can't send SMS. Unable to obtain mobile carrier."), PURPLE_MESSAGE_SYSTEM, time(NULL));


Index: pidgin.spec
===================================================================
RCS file: /cvs/extras/rpms/pidgin/F-11/pidgin.spec,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -p -r1.84 -r1.85
--- pidgin.spec	13 May 2010 11:41:33 -0000	1.84
+++ pidgin.spec	20 May 2010 02:09:28 -0000	1.85
@@ -100,7 +100,7 @@
 
 Name:		pidgin
 Version:	2.7.0
-Release:	1%{?dist}
+Release:	2%{?dist}
 License:        GPLv2+ and GPLv2 and MIT
 # GPLv2+ - libpurple, gnt, finch, pidgin, most prpls
 # GPLv2 - silc & novell prpls
@@ -133,6 +133,12 @@ Patch0: pidgin-NOT-UPSTREAM-2.5.2-rhel4-
 
 ## Patches 100+: To be Included in Future Upstream
 Patch100: pidgin-2.7.0-msn-slp-11532.patch
+Patch101: pidgin-2.7.0-icqhtml.patch
+Patch102: pidgin-2.7.0-nulldref-592750.patch
+Patch103: pidgin-2.7.0-trayblink-11855.patch
+Patch104: pidgin-2.7.0-yahooraces.patch
+Patch105: pidgin-2.7.0-oscarcrash.patch
+Patch106: pidgin-2.7.0-chatfilter.patch
 
 BuildRoot:	%{_tmppath}/%{name}-%{version}-root
 Summary:	A Gtk+ based multiprotocol instant messaging client
@@ -402,7 +408,13 @@ echo "FEDORA=%{fedora} RHEL=%{rhel}"
 %endif
 
 ## Patches 100+: To be Included in Future Upstream
-%patch100 -p0
+%patch100 -p0 -b .msnslp
+%patch101 -p0 -b .icqhtml
+%patch102 -p0 -b .nulldref
+%patch103 -p0 -b .trayblink
+%patch104 -p0 -b .yahooraces
+%patch105 -p0 -b .oscarcrash
+%patch106 -p0 -b .chatfilter
 
 # Our preferences
 cp %{SOURCE1} prefs.xml
@@ -662,7 +674,16 @@ rm -rf $RPM_BUILD_ROOT
 %endif
 
 %changelog
-* Thu May 13 2010 Stu Tomlinson <stu at nosnilmot.com> 2.7.0-1
+* Thu May 20 2010 Stu Tomlinson <stu at nosnilmot.com> 2.7.0-2
+- Upstream backports:
+    3c30f64efedafc379b6536852bbb3b6ef5f1f6c9 - fix for receiving HTML on ICQ
+    13fbe0815f84d5b3c001947559f5818c10275f4c - prevent null deref on disconnecting account (#592750)
+    c4a874926d07b8597db4b78a181a89cf720a8418 - fix blinking tray icon on new message (#592691)
+    cfe0e649dda34d9252d40d8f67e445336a247998 - prevent race condition on Yahoo! login
+    e3dd36706068f3b8eabd630ff71d270c145cce42 - fix crash in Oscar (#548128)
+    13fbe0815f84d5b3c001947559f5818c10275f4c - fix crash during network disconnect (#592750)
+
+* Thu May 13 2010 Stu Tomlinson <stu at nosnilmot.com> - 2.7.0-1
 - 2.7.0 with features, bug fixes and a security fix: CVE-2010-1624 (#591806)
 - Use System SSL Certificates (#576721)
 - Add additional dependencies for Voice + Video (#581343)



More information about the scm-commits mailing list