pidgin.2.x.y: 8221dbe3: disapproval of revision '132d9cb629620d7...

elb at pidgin.im elb at pidgin.im
Sat May 5 13:16:07 EDT 2012


----------------------------------------------------------------------
Revision: 8221dbe34324b88bd2852356a0028f0a81cda2bd
Parent:   132d9cb629620d7653e479a7b0cea75f35b2abdf
Author:   elb at pidgin.im
Date:     05/05/12 13:12:13
Branch:   im.pidgin.pidgin.2.x.y
URL: http://d.pidgin.im/viewmtn/revision/info/8221dbe34324b88bd2852356a0028f0a81cda2bd

Changelog: 

disapproval of revision '132d9cb629620d7653e479a7b0cea75f35b2abdf'

Changes against parent 132d9cb629620d7653e479a7b0cea75f35b2abdf

  patched  ChangeLog
  patched  libpurple/protocols/irc/msgs.c

-------------- next part --------------
============================================================
--- ChangeLog	d5a35afc538d75ad049329bd2c993ee0232c0a7a
+++ ChangeLog	2b793a94c12e0dfc03a8125d862702380d56b730
@@ -1,10 +1,7 @@ version 2.10.4:
 Pidgin and Finch: The Pimpin' Penguin IM Clients That're Good for the Soul
 
 version 2.10.4:
-	IRC:
-	* Disable periodic WHO timer.  IRC channel user lists will no
-	  longer automatically display away status, but libpurple will be
-	  much kinder to the network.
+	TODO
 
 version 2.10.3 (03/26/2012):
 	MSN:
============================================================
--- libpurple/protocols/irc/msgs.c	ad656d776f172c9d3cdd0c733f0a5c62e7b2152c
+++ libpurple/protocols/irc/msgs.c	1a8b5b3acaa301d0e3fefb1fbd8e9abe5dc81253
@@ -112,64 +112,13 @@ static void irc_connected(struct irc_con
 		irc->timer = purple_timeout_add_seconds(45, (GSourceFunc)irc_blist_timeout, (gpointer)irc);
 }
 
-/* This function is ugly, but it's really an error handler. */
 void irc_msg_default(struct irc_conn *irc, const char *name, const char *from, char **args)
 {
-	int i, directed_magic = TRUE;
-	char *convname, *end, *tmp, *cur;
-	PurpleConversation *convo;
-
-	for (cur = args[0], i = 0; i < 4; i++) {
-		end = strchr(cur, ' ');
-		if (cur == NULL) {
-			goto undirected;
-		}
-		/* Check for 3-digit numeric in second position */
-		if (i == 1 && (end - cur != 3
-			       || !isdigit(cur[0]) || !isdigit(cur[1])
-			       || !isdigit(cur[2]))) {
-			goto undirected;
-		}
-		/* Hack! */
-		if (i != 3) {
-			cur = end + 1;
-		}
-	}
-
-	/* At this point, cur is the beginning of the fourth position,
-	 * end is the following space, and there are remaining
-	 * arguments.  We'll check to see if this argument is a
-	 * currently active conversation (private message or channel,
-	 * either one), and print the numeric to that conversation if it
-	 * is. */
-
-	tmp = g_strndup(cur, end - cur);
-	convname = purple_utf8_salvage(tmp);
-	g_free(tmp);
-
-	/* Check for an existing conversation */
-	convo = purple_find_conversation_with_account(PURPLE_CONV_TYPE_ANY,
-						      convname,
-						      irc->account);
-	g_free(convname);
-
-	if (convo == NULL) {
-		goto undirected;
-	}
-
-	tmp = purple_utf8_salvage(args[0]);
-	purple_conversation_write(convo, "", tmp,
-				  PURPLE_MESSAGE_SYSTEM|PURPLE_MESSAGE_NO_LOG
-				  |PURPLE_MESSAGE_RAW|PURPLE_MESSAGE_NO_LINKIFY,
-				  time(NULL));
-	g_free(tmp);
-	return;
-
-  undirected:
+	char *clean;
 	/* This, too, should be escaped somehow (smarter) */
-	tmp = purple_utf8_salvage(args[0]);
-	purple_debug(PURPLE_DEBUG_INFO, "irc", "Unrecognized message: %s\n", tmp);
-	g_free(tmp);
+	clean = purple_utf8_salvage(args[0]);
+	purple_debug(PURPLE_DEBUG_INFO, "irc", "Unrecognized message: %s\n", clean);
+	g_free(clean);
 }
 
 void irc_msg_features(struct irc_conn *irc, const char *name, const char *from, char **args)


More information about the Commits mailing list