changeset 25443:5f9a24d1c25e

Remove some extra trailing whitespace I noticed after merging mlundblad's xmpp branches.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Mon, 02 Mar 2009 06:37:05 +0000
parents 13574de83636
children 33b8ac883b33
files libpurple/protocols/jabber/adhoccommands.c libpurple/protocols/jabber/auth.c libpurple/protocols/jabber/buddy.c libpurple/protocols/jabber/caps.c libpurple/protocols/jabber/chat.c libpurple/protocols/jabber/data.c libpurple/protocols/jabber/data.h libpurple/protocols/jabber/disco.c libpurple/protocols/jabber/ibb.c libpurple/protocols/jabber/ibb.h libpurple/protocols/jabber/iq.c libpurple/protocols/jabber/jabber.c libpurple/protocols/jabber/jabber.h libpurple/protocols/jabber/libxmpp.c libpurple/protocols/jabber/message.c libpurple/protocols/jabber/pep.c libpurple/protocols/jabber/presence.c libpurple/protocols/jabber/roster.c libpurple/protocols/jabber/si.c libpurple/protocols/jabber/usermood.c libpurple/protocols/jabber/usernick.c libpurple/protocols/jabber/usertune.c libpurple/protocols/jabber/xdata.c
diffstat 23 files changed, 407 insertions(+), 407 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/jabber/adhoccommands.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/adhoccommands.c	Mon Mar 02 06:37:05 2009 +0000
@@ -47,26 +47,26 @@
 	JabberID *jabberid;
 	JabberBuddy *jb;
 	JabberBuddyResource *jbr = NULL;
-	
+
 	if(strcmp(type, "result"))
 		return;
-	
+
 	query = xmlnode_get_child_with_namespace(packet,"query","http://jabber.org/protocol/disco#items");
 	if(!query)
 		return;
 	node = xmlnode_get_attrib(query,"node");
 	if(!node || strcmp(node, "http://jabber.org/protocol/commands"))
 		return;
-	
+
 	if((jabberid = jabber_id_new(from))) {
 		if(jabberid->resource && (jb = jabber_buddy_find(js, from, TRUE)))
 			jbr = jabber_buddy_find_resource(jb, jabberid->resource);
 		jabber_id_free(jabberid);
 	}
-	
+
 	if(!jbr)
 		return;
-	
+
 	if(jbr->commands) {
 		/* since the list we just received is complete, wipe the old one */
 		while(jbr->commands) {
@@ -78,7 +78,7 @@
 			jbr->commands = g_list_delete_link(jbr->commands, jbr->commands);
 		}
 	}
-	
+
 	for(item = query->child; item; item = item->next) {
 		JabberAdHocCommands *cmd;
 		if(item->type != XMLNODE_TYPE_TAG)
@@ -86,11 +86,11 @@
 		if(strcmp(item->name, "item"))
 			continue;
 		cmd = g_new0(JabberAdHocCommands, 1);
-		
+
 		cmd->jid = g_strdup(xmlnode_get_attrib(item,"jid"));
 		cmd->node = g_strdup(xmlnode_get_attrib(item,"node"));
 		cmd->name = g_strdup(xmlnode_get_attrib(item,"name"));
-		
+
 		jbr->commands = g_list_append(jbr->commands,cmd);
 	}
 }
@@ -103,13 +103,13 @@
 	JabberAdHocActionInfo *actionInfo = user_data;
 	JabberIq *iq = jabber_iq_new(js, JABBER_IQ_SET);
 	jabber_iq_set_callback(iq, jabber_adhoc_parse, NULL);
-	
+
 	xmlnode_set_attrib(iq->node, "to", actionInfo->who);
 	command = xmlnode_new_child(iq->node,"command");
 	xmlnode_set_namespace(command,"http://jabber.org/protocol/commands");
 	xmlnode_set_attrib(command,"sessionid",actionInfo->sessionid);
 	xmlnode_set_attrib(command,"node",actionInfo->node);
-	
+
 	/* cancel is handled differently on ad-hoc commands than regular forms */
 	if(!strcmp(xmlnode_get_namespace(result),"jabber:x:data") && !strcmp(xmlnode_get_attrib(result, "type"),"cancel")) {
 		xmlnode_set_attrib(command,"action","cancel");
@@ -118,7 +118,7 @@
 			xmlnode_set_attrib(command,"action",actionhandle);
 		xmlnode_insert_child(command,result);
 	}
-	
+
 	for(action = actionInfo->actionslist; action; action = g_list_next(action)) {
 		char *handle = action->data;
 		g_free(handle);
@@ -127,7 +127,7 @@
 	g_free(actionInfo->sessionid);
 	g_free(actionInfo->who);
 	g_free(actionInfo->node);
-	
+
 	jabber_iq_send(iq);
 }
 
@@ -136,12 +136,12 @@
 	const char *status = xmlnode_get_attrib(command,"status");
 	xmlnode *xdata = xmlnode_get_child_with_namespace(command,"x","jabber:x:data");
 	const char *type = xmlnode_get_attrib(packet,"type");
-	
+
 	if(type && !strcmp(type,"error")) {
 		char *msg = jabber_parse_error(js, packet, NULL);
 		if(!msg)
 			msg = g_strdup(_("Unknown Error"));
-		
+
 		purple_notify_error(NULL, _("Ad-Hoc Command Failed"),
 							_("Ad-Hoc Command Failed"), msg);
 		g_free(msg);
@@ -149,20 +149,20 @@
 	}
 	if(!type || strcmp(type,"result"))
 		return;
-	
+
 	if(!status)
 		return;
-	
+
 	if(!strcmp(status,"completed")) {
 		/* display result */
 		xmlnode *note = xmlnode_get_child(command,"note");
-		
+
 		if(note) {
 			char *data = xmlnode_get_data(note);
 			purple_notify_info(NULL, xmlnode_get_attrib(packet, "from"), data, NULL);
 			g_free(data);
 		}
-		
+
 		if(xdata)
 			jabber_x_data_request(js, xdata, (jabber_x_data_cb)do_adhoc_ignoreme, NULL);
 		return;
@@ -175,7 +175,7 @@
 		JabberAdHocActionInfo *actionInfo;
 		if(!xdata)
 			return; /* shouldn't happen */
-		
+
 		actions = xmlnode_get_child(command,"actions");
 		if(!actions) {
 			JabberXDataAction *defaultaction = g_new0(JabberXDataAction, 1);
@@ -196,13 +196,13 @@
 				}
 			}
 		}
-		
+
 		actionInfo = g_new0(JabberAdHocActionInfo, 1);
 		actionInfo->sessionid = g_strdup(xmlnode_get_attrib(command,"sessionid"));
 		actionInfo->who = g_strdup(xmlnode_get_attrib(packet,"from"));
 		actionInfo->node = g_strdup(xmlnode_get_attrib(command,"node"));
 		actionInfo->actionslist = actionslist;
-		
+
 		jabber_x_data_request_with_actions(js,xdata,actionslist,actionindex,do_adhoc_action_cb,actionInfo);
 	}
 }
@@ -221,7 +221,7 @@
 static void jabber_adhoc_server_got_list_cb(JabberStream *js, xmlnode *packet, gpointer data) {
 	xmlnode *query = xmlnode_get_child_with_namespace(packet, "query", "http://jabber.org/protocol/disco#items");
 	xmlnode *item;
-	
+
 	if(!query)
 		return;
 
@@ -234,7 +234,7 @@
 		g_free(cmd);
 		js->commands = g_list_delete_link(js->commands, js->commands);
 	}
-	
+
 	/* re-fill list */
 	for(item = query->child; item; item = item->next) {
 		JabberAdHocCommands *cmd;
@@ -246,7 +246,7 @@
 		cmd->jid = g_strdup(xmlnode_get_attrib(item,"jid"));
 		cmd->node = g_strdup(xmlnode_get_attrib(item,"node"));
 		cmd->name = g_strdup(xmlnode_get_attrib(item,"name"));
-		
+
 		js->commands = g_list_append(js->commands,cmd);
 	}
 }
@@ -254,10 +254,10 @@
 void jabber_adhoc_server_get_list(JabberStream *js) {
 	JabberIq *iq = jabber_iq_new_query(js,JABBER_IQ_GET,"http://jabber.org/protocol/disco#items");
 	xmlnode *query = xmlnode_get_child_with_namespace(iq->node,"query","http://jabber.org/protocol/disco#items");
-	
+
 	xmlnode_set_attrib(iq->node,"to",js->user->domain);
 	xmlnode_set_attrib(query,"node","http://jabber.org/protocol/commands");
-	
+
 	jabber_iq_set_callback(iq,jabber_adhoc_server_got_list_cb,NULL);
 	jabber_iq_send(iq);
 }
@@ -269,9 +269,9 @@
 	xmlnode_set_namespace(command,"http://jabber.org/protocol/commands");
 	xmlnode_set_attrib(command,"node",cmd->node);
 	xmlnode_set_attrib(command,"action","execute");
-	
+
 	jabber_iq_set_callback(iq,jabber_adhoc_parse,NULL);
-	
+
 	jabber_iq_send(iq);
 }
 
@@ -280,7 +280,7 @@
 	if(cmd) {
 		PurpleConnection *gc = (PurpleConnection *) action->context;
 		JabberStream *js = gc->proto_data;
-		
+
 		jabber_adhoc_execute(js, cmd);
 	}
 }
@@ -288,7 +288,7 @@
 void jabber_adhoc_init_server_commands(JabberStream *js, GList **m) {
 	GList *cmdlst;
 	JabberBuddy *jb;
-	
+
 	/* also add commands for other clients connected to the same account on another resource */
 	char *accountname = g_strdup_printf("%s@%s", js->user->node, js->user->domain);
 	if((jb = jabber_buddy_find(js, accountname, TRUE))) {
@@ -307,7 +307,7 @@
 		}
 	}
 	g_free(accountname);
-	
+
 	/* now add server commands */
 	for(cmdlst = js->commands; cmdlst; cmdlst = g_list_next(cmdlst)) {
 		JabberAdHocCommands *cmd = cmdlst->data;
--- a/libpurple/protocols/jabber/auth.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/auth.c	Mon Mar 02 06:37:05 2009 +0000
@@ -384,7 +384,7 @@
 					}
 					/* Remove space which separated this mech from the next */
 					if (strlen(js->sasl_mechs->str) > 0 && ((js->sasl_mechs->str)[0] == ' ')) {
-						g_string_erase(js->sasl_mechs, 0, 1);	
+						g_string_erase(js->sasl_mechs, 0, 1);
 					}
 					again = TRUE;
 				}
@@ -397,7 +397,7 @@
 		auth = xmlnode_new("auth");
 		xmlnode_set_namespace(auth, "urn:ietf:params:xml:ns:xmpp-sasl");
 		xmlnode_set_attrib(auth, "mechanism", js->current_mech);
-		
+
 		xmlnode_set_attrib(auth, "xmlns:ga", "http://www.google.com/talk/protocol/auth");
 		xmlnode_set_attrib(auth, "ga:client-uses-full-bind-result", "true");
 
@@ -1057,13 +1057,13 @@
 			}
 			/* Remove space which separated this mech from the next */
 			if (strlen(js->sasl_mechs->str) > 0 && ((js->sasl_mechs->str)[0] == ' ')) {
-				g_string_erase(js->sasl_mechs, 0, 1);	
-			}			
+				g_string_erase(js->sasl_mechs, 0, 1);
+			}
 		}
 		if (strlen(js->sasl_mechs->str)) {
 			/* If we have remaining mechs to try, do so */
 			sasl_dispose(&js->sasl);
-			
+
 			jabber_auth_start_cyrus(js);
 			return;
 		}
--- a/libpurple/protocols/jabber/buddy.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/buddy.c	Mon Mar 02 06:37:05 2009 +0000
@@ -170,7 +170,7 @@
 	g_return_if_fail(jbr != NULL);
 
 	jbr->jb->resources = g_list_remove(jbr->jb->resources, jbr);
-	
+
 	while(jbr->commands) {
 		JabberAdHocCommands *cmd = jbr->commands->data;
 		g_free(cmd->jid);
@@ -179,7 +179,7 @@
 		g_free(cmd);
 		jbr->commands = g_list_delete_link(jbr->commands, jbr->commands);
 	}
-	
+
 	jabber_caps_free_clientinfo(jbr->caps);
 
 	g_free(jbr->name);
@@ -495,7 +495,7 @@
 {
 	PurplePresence *gpresence;
 	PurpleStatus *status;
-	
+
 	if(((JabberStream*)purple_connection_get_protocol_data(gc))->pep) {
 		/* XEP-0084: User Avatars */
 		if(img) {
@@ -539,37 +539,37 @@
 				guint32 height = ntohl(png->ihdr.height);
 				xmlnode *publish, *item, *data, *metadata, *info;
 				char *lengthstring, *widthstring, *heightstring;
-				
+
 				/* compute the sha1 hash */
 				char *hash = jabber_calculate_data_sha1sum(purple_imgstore_get_data(img), purple_imgstore_get_size(img));
 				char *base64avatar;
-				
+
 				publish = xmlnode_new("publish");
 				xmlnode_set_attrib(publish,"node",AVATARNAMESPACEDATA);
-				
+
 				item = xmlnode_new_child(publish, "item");
 				xmlnode_set_attrib(item, "id", hash);
-				
+
 				data = xmlnode_new_child(item, "data");
 				xmlnode_set_namespace(data,AVATARNAMESPACEDATA);
-				
+
 				base64avatar = purple_base64_encode(purple_imgstore_get_data(img), purple_imgstore_get_size(img));
 				xmlnode_insert_data(data,base64avatar,-1);
 				g_free(base64avatar);
-				
+
 				/* publish the avatar itself */
 				jabber_pep_publish((JabberStream*)purple_connection_get_protocol_data(gc), publish);
-				
+
 				/* next step: publish the metadata */
 				publish = xmlnode_new("publish");
 				xmlnode_set_attrib(publish,"node",AVATARNAMESPACEMETA);
-				
+
 				item = xmlnode_new_child(publish, "item");
 				xmlnode_set_attrib(item, "id", hash);
-				
+
 				metadata = xmlnode_new_child(item, "metadata");
 				xmlnode_set_namespace(metadata,AVATARNAMESPACEMETA);
-				
+
 				info = xmlnode_new_child(metadata, "info");
 				xmlnode_set_attrib(info, "id", hash);
 				xmlnode_set_attrib(info, "type", "image/png");
@@ -582,10 +582,10 @@
 				heightstring = g_strdup_printf("%u", height);
 				xmlnode_set_attrib(info, "height", heightstring);
 				g_free(heightstring);
-				
+
 				/* publish the metadata */
 				jabber_pep_publish((JabberStream*)purple_connection_get_protocol_data(gc), publish);
-				
+
 				g_free(hash);
 			} else {
 				purple_debug_error("jabber", "jabber_set_buddy_icon received non-png data");
@@ -796,18 +796,18 @@
 								  (jbr->client.version ? jbr->client.version : ""));
 			purple_notify_user_info_add_pair(user_info, _("Client"), tmp);
 			g_free(tmp);
-			
+
 			if(jbr->client.os) {
 				purple_notify_user_info_prepend_pair(user_info, _("Operating System"), jbr->client.os);
 			}
-		}		
+		}
 		if(jbir) {
 			if(jbir->idle_seconds > 0) {
 				char *idle = purple_str_seconds_to_string(jbir->idle_seconds);
 				purple_notify_user_info_prepend_pair(user_info, _("Idle"), idle);
 				g_free(idle);
 			}
-		}		
+		}
 		if(jbr) {
 			char *purdy = NULL;
 			const char *status_name = jabber_buddy_state_get_name(jbr->state);
@@ -825,7 +825,7 @@
 		} else {
 			purple_notify_user_info_prepend_pair(user_info, _("Status"), _("Unknown"));
 		}
-#if 0 
+#if 0
 		/* #if 0 this for now; I think this would be far more useful if we limited this to a particular set of features
  		 * of particular interest (-vv jumps out as one). As it is now, I don't picture people getting all excited: "Oh sweet crap!
  		 * So-and-so supports 'jabber:x:data' AND 'Collaborative Data Objects'!"
@@ -836,7 +836,7 @@
 			GList *iter;
 			for(iter = jbr->caps->features; iter; iter = g_list_next(iter)) {
 				const char *feature = iter->data;
-				
+
 				if(!strcmp(feature, "jabber:iq:last"))
 					feature = _("Last Activity");
 				else if(!strcmp(feature, "http://jabber.org/protocol/disco#info"))
@@ -945,7 +945,7 @@
 
 			if(strlen(tmp->str) > 0)
 				purple_notify_user_info_prepend_pair(user_info, _("Capabilities"), tmp->str);
-			
+
 			g_string_free(tmp, TRUE);
 		}
 #endif
@@ -965,7 +965,7 @@
 				purple_notify_user_info_prepend_pair(user_info,
 												 _("Client"), tmp);
 				g_free(tmp);
-				
+
 				if(jbr->client.os) {
 					purple_notify_user_info_prepend_pair(user_info, _("Operating System"), jbr->client.os);
 				}
@@ -984,14 +984,14 @@
 				purdy = purple_strdup_withhtml(jbr->status);
 			if(status_name && purdy && !strcmp(status_name, purdy))
 				status_name = NULL;
-			
+
 			tmp = g_strdup_printf("%s%s%s", (status_name ? status_name : ""),
 								  ((status_name && purdy) ? ": " : ""),
 								  (purdy ? purdy : ""));
 			purple_notify_user_info_prepend_pair(user_info, _("Status"), tmp);
 			g_free(tmp);
 			g_free(purdy);
-			
+
 			if(multiple_resources) {
 				tmp = g_strdup_printf("%d", jbr->priority);
 				purple_notify_user_info_prepend_pair(user_info, _("Priority"), tmp);
@@ -1006,7 +1006,7 @@
 				GList *iter;
 				for(iter = jbr->caps->features; iter; iter = g_list_next(iter)) {
 					const char *feature = iter->data;
-					
+
 					if(!strcmp(feature, "jabber:iq:last"))
 						feature = _("Last Activity");
 					else if(!strcmp(feature, "http://jabber.org/protocol/disco#info"))
@@ -1109,13 +1109,13 @@
 						feature = _("Hop Check");
 					else if(g_str_has_suffix(feature, "+notify"))
 						feature = NULL;
-					
+
 					if(feature)
 						g_string_append_printf(tmp, "%s\n", feature);
 				}
 				if(strlen(tmp->str) > 0)
 					purple_notify_user_info_prepend_pair(user_info, _("Capabilities"), tmp->str);
-				
+
 				g_string_free(tmp, TRUE);
 			}
 #endif
@@ -1183,7 +1183,7 @@
 void jabber_vcard_fetch_mine(JabberStream *js)
 {
 	JabberIq *iq = jabber_iq_new(js, JABBER_IQ_GET);
-	
+
 	xmlnode *vcard = xmlnode_new_child(iq->node, "vCard");
 	xmlnode_set_namespace(vcard, "vcard-temp");
 	jabber_iq_set_callback(iq, jabber_vcard_save_mine, NULL);
@@ -1257,13 +1257,13 @@
 					}
 					g_free(text2);
 				}
-			} else if(text && !strcmp(child->name, "NICKNAME")) {				
+			} else if(text && !strcmp(child->name, "NICKNAME")) {
 				/* Prefer the Nickcname to the Full Name as the serverside alias if it's not just part of the jid.
 				 * Ignore it if it's part of the jid. */
 				if (strstr(bare_jid, text) == NULL) {
 					g_free(serverside_alias);
 					serverside_alias = g_strdup(text);
-					
+
 					purple_notify_user_info_add_pair(user_info, _("Nickname"), text);
 				}
 			} else if(text && !strcmp(child->name, "BDAY")) {
@@ -1308,7 +1308,7 @@
 					}
 					g_free(text2);
 				}
-				
+
 				if (address_line_added)
 					purple_notify_user_info_add_section_break(user_info);
 
@@ -1350,8 +1350,8 @@
 					escaped = g_markup_escape_text(userid, -1);
 					mailto = g_strdup_printf("<a href=\"mailto:%s\">%s</a>", escaped, escaped);
 					purple_notify_user_info_add_pair(user_info, _("Email"), mailto);
-					
-					g_free(mailto);					
+
+					g_free(mailto);
 					g_free(escaped);
 					g_free(userid);
 				}
@@ -1418,7 +1418,7 @@
 		if (b) {
 			purple_blist_node_set_string((PurpleBlistNode*)b, "servernick", serverside_alias);
 		}
-		
+
 		g_free(serverside_alias);
 	}
 
@@ -1440,7 +1440,7 @@
 					 "do_buddy_avatar_update_fromurl got error \"%s\"", error_message);
 		return;
 	}
-	
+
 	purple_buddy_icons_set_for_user(purple_connection_get_account(info->js->gc), info->from, (void*)url_text, len, info->id);
 	g_free(info->from);
 	g_free(info->id);
@@ -1455,29 +1455,29 @@
 	size_t size;
 	if(!items)
 		return;
-	
+
 	item = xmlnode_get_child(items, "item");
 	if(!item)
 		return;
-	
+
 	data = xmlnode_get_child_with_namespace(item,"data",AVATARNAMESPACEDATA);
 	if(!data)
 		return;
-	
+
 	checksum = xmlnode_get_attrib(item,"id");
 	if(!checksum)
 		return;
-	
+
 	b64data = xmlnode_get_data(data);
 	if(!b64data)
 		return;
-	
+
 	img = purple_base64_decode(b64data, &size);
 	if(!img) {
 		g_free(b64data);
 		return;
 	}
-	
+
 	purple_buddy_icons_set_for_user(purple_connection_get_account(js->gc), from, img, size, checksum);
 	g_free(b64data);
 }
@@ -1488,7 +1488,7 @@
 	xmlnode *item, *metadata;
 	if(!buddy)
 		return;
-	
+
 	checksum = purple_buddy_icons_get_checksum_for_user(buddy);
 	item = xmlnode_get_child(items,"item");
 	metadata = xmlnode_get_child_with_namespace(item, "metadata", AVATARNAMESPACEMETA);
@@ -1508,7 +1508,7 @@
 			if(info->type == XMLNODE_TYPE_TAG && !strcmp(info->name,"info")) {
 				const char *type = xmlnode_get_attrib(info,"type");
 				const char *id = xmlnode_get_attrib(info,"id");
-				
+
 				if(checksum && id && !strcmp(id, checksum)) {
 					/* we already have that avatar, so we don't have to do anything */
 					goodinfo = NULL;
@@ -1524,7 +1524,7 @@
 		} else if(goodinfo) {
 			const char *url = xmlnode_get_attrib(goodinfo, "url");
 			const char *id = xmlnode_get_attrib(goodinfo,"id");
-			
+
 			/* the avatar might either be stored in a pep node, or on a HTTP/HTTPS URL */
 			if(!url)
 				jabber_pep_request_item(js, from, AVATARNAMESPACEDATA, id, do_buddy_avatar_update_data);
@@ -1922,14 +1922,14 @@
 		JabberBuddyState state;
 		char *msg;
 		int priority;
-		
+
 		purple_status_to_jabber(status, &state, &msg, &priority);
 		presence = jabber_presence_create_js(js, state, msg, priority);
-		
+
 		g_free(msg);
-		
+
 		xmlnode_set_attrib(presence, "to", purple_buddy_get_name(buddy));
-		
+
 		jabber_send(js, presence);
 		xmlnode_free(presence);
 	}
@@ -1942,11 +1942,11 @@
 		PurpleConnection *gc = purple_account_get_connection(purple_buddy_get_account(buddy));
 		JabberStream *js = purple_connection_get_protocol_data(gc);
 		xmlnode *presence;
-		
+
 		presence = jabber_presence_create_js(js, JABBER_BUDDY_STATE_UNAVAILABLE, NULL, 0);
-		
+
 		xmlnode_set_attrib(presence, "to", purple_buddy_get_name(buddy));
-		
+
 		jabber_send(js, presence);
 		xmlnode_free(presence);
 	}
@@ -2003,7 +2003,7 @@
 		                           NULL, NULL);
 		m = g_list_append(m, act);
 	}
-	
+
 	/*
 	 * This if-condition implements parts of XEP-0100: Gateway Interaction
 	 *
@@ -2022,7 +2022,7 @@
 									 NULL, NULL);
 		m = g_list_append(m, act);
 	}
-	
+
 	/* add all ad hoc commands to the action menu */
 	for(jbrs = jb->resources; jbrs; jbrs = g_list_next(jbrs)) {
 		JabberBuddyResource *jbr = jbrs->data;
--- a/libpurple/protocols/jabber/caps.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/caps.c	Mon Mar 02 06:37:05 2009 +0000
@@ -51,7 +51,7 @@
 	const JabberCapsKey *name = key;
 	guint nodehash = g_str_hash(name->node);
 	guint verhash = g_str_hash(name->ver);
-	
+
 	return nodehash ^ verhash;
 }
 
@@ -77,7 +77,7 @@
 		g_free(id->type);
 		g_free(id->name);
 		g_free(id);
-		
+
 		valuestruct->identities = g_list_delete_link(valuestruct->identities,valuestruct->identities);
 	}
 	while(valuestruct->features) {
@@ -96,7 +96,7 @@
 		g_free(id->type);
 		g_free(id->name);
 		g_free(id);
-		
+
 		valuestruct->identities = g_list_delete_link(valuestruct->identities,valuestruct->identities);
 	}
 	while(valuestruct->features) {
@@ -124,7 +124,7 @@
 		xmlnode_free(capsdata);
 		return;
 	}
-	
+
 	for(client = capsdata->child; client; client = client->next) {
 		if(client->type != XMLNODE_TYPE_TAG)
 			continue;
@@ -147,20 +147,20 @@
 					const char *category = xmlnode_get_attrib(child, "category");
 					const char *type = xmlnode_get_attrib(child, "type");
 					const char *name = xmlnode_get_attrib(child, "name");
-					
+
 					JabberCapsIdentity *id = g_new0(JabberCapsIdentity, 1);
 					id->category = g_strdup(category);
 					id->type = g_strdup(type);
 					id->name = g_strdup(name);
-					
+
 					value->identities = g_list_append(value->identities,id);
 				} else if(!strcmp(child->name,"ext")) {
 					const char *identifier = xmlnode_get_attrib(child, "identifier");
 					if(identifier) {
 						xmlnode *extchild;
-						
+
 						JabberCapsValueExt *extvalue = g_new0(JabberCapsValueExt, 1);
-						
+
 						for(extchild = child->child; extchild; extchild = extchild->next) {
 							if(extchild->type != XMLNODE_TYPE_TAG)
 								continue;
@@ -173,12 +173,12 @@
 								const char *category = xmlnode_get_attrib(extchild, "category");
 								const char *type = xmlnode_get_attrib(extchild, "type");
 								const char *name = xmlnode_get_attrib(extchild, "name");
-								
+
 								JabberCapsIdentity *id = g_new0(JabberCapsIdentity, 1);
 								id->category = g_strdup(category);
 								id->type = g_strdup(type);
 								id->name = g_strdup(name);
-								
+
 								extvalue->identities = g_list_append(extvalue->identities,id);
 							}
 						}
@@ -226,7 +226,7 @@
 
 	xmlnode_set_attrib(client,"node",clientinfo->node);
 	xmlnode_set_attrib(client,"ver",clientinfo->ver);
-	
+
 	for(iter = props->identities; iter; iter = g_list_next(iter)) {
 		JabberCapsIdentity *id = iter->data;
 		xmlnode *identity = xmlnode_new_child(client, "identity");
@@ -241,7 +241,7 @@
 		xmlnode *feature = xmlnode_new_child(client, "feature");
 		xmlnode_set_attrib(feature, "var", feat);
 	}
-	
+
 	g_hash_table_foreach(props->ext,jabber_caps_store_ext,client);
 }
 
@@ -281,20 +281,20 @@
 		newid->category = g_strdup(id->category);
 		newid->type = g_strdup(id->type);
 		newid->name = g_strdup(id->name);
-		
+
 		result->identities = g_list_append(result->identities,newid);
 	}
 	for(iter = caps->features; iter; iter = g_list_next(iter)) {
 		const char *feat = iter->data;
 		char *newfeat = g_strdup(feat);
-		
+
 		result->features = g_list_append(result->features,newfeat);
 	}
-	
+
 	for(iter = ext; iter; iter = g_list_next(iter)) {
 		const char *extname = iter->data;
 		JabberCapsValueExt *extinfo = g_hash_table_lookup(caps->ext,extname);
-		
+
 		if(extinfo) {
 			GList *iter2;
 			for(iter2 = extinfo->identities; iter2; iter2 = g_list_next(iter2)) {
@@ -303,13 +303,13 @@
 				newid->category = g_strdup(id->category);
 				newid->type = g_strdup(id->type);
 				newid->name = g_strdup(id->name);
-				
+
 				result->identities = g_list_append(result->identities,newid);
 			}
 			for(iter2 = extinfo->features; iter2; iter2 = g_list_next(iter2)) {
 				const char *feat = iter2->data;
 				char *newfeat = g_strdup(feat);
-				
+
 				result->features = g_list_append(result->features,newfeat);
 			}
 		}
@@ -326,23 +326,23 @@
 		g_free(id->type);
 		g_free(id->name);
 		g_free(id);
-		
+
 		clientinfo->identities = g_list_delete_link(clientinfo->identities,clientinfo->identities);
 	}
 	while(clientinfo->features) {
 		char *feat = clientinfo->features->data;
 		g_free(feat);
-		
+
 		clientinfo->features = g_list_delete_link(clientinfo->features,clientinfo->features);
 	}
-	
+
 	g_free(clientinfo);
 }
 
 typedef struct _jabber_caps_cbplususerdata {
 	jabber_caps_get_info_cb cb;
 	gpointer user_data;
-	
+
 	char *who;
 	char *node;
 	char *ver;
--- a/libpurple/protocols/jabber/chat.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/chat.c	Mon Mar 02 06:37:05 2009 +0000
@@ -353,7 +353,7 @@
 	jcm = g_hash_table_lookup(chat->members, who);
 	if (jcm != NULL && jcm->jid)
 		return g_strdup(jcm->jid);
-	
+
 
 	return g_strdup_printf("%s@%s/%s", chat->room, chat->server, who);
 }
@@ -685,7 +685,7 @@
 		xmlnode_insert_data(status, msg, -1);
 	}
 	jabber_send(chat->js, presence);
-	
+
 	xmlnode_free(presence);
 	g_free(room_jid);
 }
@@ -811,7 +811,7 @@
 			FALSE, FALSE, NULL,
 			_("Find Rooms"), PURPLE_CALLBACK(roomlist_ok_cb),
 			_("Cancel"), PURPLE_CALLBACK(roomlist_cancel_cb),
-			purple_connection_get_account(gc), NULL, NULL,			 
+			purple_connection_get_account(gc), NULL, NULL,
 			js);
 
 	return js->roomlist;
@@ -1033,7 +1033,7 @@
 	iq = jabber_iq_new_query(chat->js, JABBER_IQ_GET,
 			"http://jabber.org/protocol/disco#info");
 
-	xmlnode_set_attrib(iq->node, "to", room_jid); 
+	xmlnode_set_attrib(iq->node, "to", room_jid);
 
 	query = xmlnode_get_child(iq->node, "query");
 
--- a/libpurple/protocols/jabber/data.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/data.c	Mon Mar 02 06:37:05 2009 +0000
@@ -3,17 +3,17 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU Library General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 #include <stdlib.h>
 #include <glib.h>
 #include <string.h>
@@ -71,7 +71,7 @@
 
 	data->cid = g_strdup(xmlnode_get_attrib(tag, "cid"));
 	data->type = g_strdup(xmlnode_get_attrib(tag, "type"));
-	
+
 	raw_data = xmlnode_get_data(tag);
 	data->data = purple_base64_decode(raw_data, &size);
 	data->size = size;
@@ -176,7 +176,7 @@
 jabber_data_find_remote_by_cid(const gchar *cid)
 {
 	purple_debug_info("jabber", "lookup remote smiley with cid = %s\n", cid);
-	
+
 	return g_hash_table_lookup(remote_data_by_cid, cid);
 }
 
@@ -186,7 +186,7 @@
 	purple_debug_info("jabber", "associating local smiley\n alt = %s, cid = %s\n",
 		alt, jabber_data_get_cid(data));
 	g_hash_table_insert(local_data_by_alt, g_strdup(alt), data);
-	g_hash_table_insert(local_data_by_cid, g_strdup(jabber_data_get_cid(data)), 
+	g_hash_table_insert(local_data_by_cid, g_strdup(jabber_data_get_cid(data)),
 		data);
 }
 
@@ -195,7 +195,7 @@
 {
 	purple_debug_info("jabber", "associating remote smiley, cid = %s\n",
 		jabber_data_get_cid(data));
-	g_hash_table_insert(remote_data_by_cid, g_strdup(jabber_data_get_cid(data)), 
+	g_hash_table_insert(remote_data_by_cid, g_strdup(jabber_data_get_cid(data)),
 		data);
 }
 
--- a/libpurple/protocols/jabber/data.h	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/data.h	Mon Mar 02 06:37:05 2009 +0000
@@ -3,17 +3,17 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU Library General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 #ifndef JABBER_DATA_H
 #define JABBER_DATA_H
 
--- a/libpurple/protocols/jabber/disco.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/disco.c	Mon Mar 02 06:37:05 2009 +0000
@@ -140,7 +140,7 @@
 			SUPPORT_FEATURE("http://jabber.org/protocol/xhtml-im")
 			SUPPORT_FEATURE("urn:xmpp:ping")
 			SUPPORT_FEATURE("http://www.xmpp.org/extensions/xep-0199.html#ns")
-			
+
 			if(!node) { /* non-caps disco#info, add all enabled extensions */
 				GList *features;
 				for(features = jabber_features; features; features = features->next) {
@@ -166,7 +166,7 @@
 					} else if(node[pos] != CAPS0115_NODE[pos])
 					break;
 				}
-				
+
 				if(ext != NULL) {
 					/* look for that ext */
 					GList *features;
@@ -181,14 +181,14 @@
 						ext = NULL;
 				}
 			}
-			
+
 			if(ext == NULL) {
 				xmlnode *error, *inf;
-				
+
 				/* XXX: gross hack, implement jabber_iq_set_type or something */
 				xmlnode_set_attrib(iq->node, "type", "error");
 				iq->type = JABBER_IQ_ERROR;
-				
+
 				error = xmlnode_new_child(query, "error");
 				xmlnode_set_attrib(error, "code", "404");
 				xmlnode_set_attrib(error, "type", "cancel");
@@ -318,7 +318,7 @@
 	if(type && !strcmp(type, "get")) {
 		JabberIq *iq = jabber_iq_new_query(js, JABBER_IQ_RESULT,
 				"http://jabber.org/protocol/disco#items");
-		
+
 		/* preserve node */
 		xmlnode *iq_query = xmlnode_get_child_with_namespace(iq->node,"query","http://jabber.org/protocol/disco#items");
 		if(iq_query) {
--- a/libpurple/protocols/jabber/ibb.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/ibb.c	Mon Mar 02 06:37:05 2009 +0000
@@ -3,17 +3,17 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU Library General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 #include "internal.h"
 #include "ibb.h"
 #include "debug.h"
@@ -25,7 +25,7 @@
 static GList *open_handlers = NULL;
 
 JabberIBBSession *
-jabber_ibb_session_create(JabberStream *js, const gchar *sid, const gchar *who, 
+jabber_ibb_session_create(JabberStream *js, const gchar *sid, const gchar *who,
 	gpointer user_data)
 {
 	JabberIBBSession *sess = g_new0(JabberIBBSession, 1);
@@ -39,9 +39,9 @@
 	sess->block_size = JABBER_IBB_SESSION_DEFAULT_BLOCK_SIZE;
 	sess->state = JABBER_IBB_SESSION_NOT_OPENED;
 	sess->user_data = user_data;
-	
+
 	g_hash_table_insert(jabber_ibb_sessions, sess->sid, sess);
-	
+
 	return sess;
 }
 
@@ -54,13 +54,13 @@
 		XEP_0047_NAMESPACE);
 	const gchar *sid = xmlnode_get_attrib(open, "sid");
 	const gchar *block_size = xmlnode_get_attrib(open, "block-size");
-	
+
 	if (!open) {
 		return NULL;
 	}
 
 	if (!sid || !block_size) {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"IBB session open tag requires sid and block-size attributes\n");
 		g_free(sess);
 		return NULL;
@@ -73,29 +73,29 @@
 	/* if we create a session from an incoming <open/> request, it means the
 	  session is immediatly open... */
 	sess->state = JABBER_IBB_SESSION_OPENED;
-	
+
 	return sess;
 }
 
 void
 jabber_ibb_session_destroy(JabberIBBSession *sess)
 {
-	purple_debug_info("jabber", "IBB: destroying session %p %s\n", sess, 
+	purple_debug_info("jabber", "IBB: destroying session %p %s\n", sess,
 		sess->sid);
-	
+
 	if (jabber_ibb_session_get_state(sess) == JABBER_IBB_SESSION_OPENED) {
 		jabber_ibb_session_close(sess);
 	}
-	
+
 	if (sess->last_iq_id) {
 		purple_debug_info("jabber", "IBB: removing callback for <iq/> %s\n",
 			sess->last_iq_id);
-		jabber_iq_remove_callback_by_id(jabber_ibb_session_get_js(sess), 
+		jabber_iq_remove_callback_by_id(jabber_ibb_session_get_js(sess),
 			sess->last_iq_id);
 		g_free(sess->last_iq_id);
 		sess->last_iq_id = NULL;
 	}
-	
+
 	g_hash_table_remove(jabber_ibb_sessions, sess->sid);
 	g_free(sess->id);
 	g_free(sess->sid);
@@ -133,7 +133,7 @@
 	return sess->recv_seq;
 }
 
-JabberIBBSessionState 
+JabberIBBSessionState
 jabber_ibb_session_get_state(const JabberIBBSession *sess)
 {
 	return sess->state;
@@ -151,7 +151,7 @@
 	if (jabber_ibb_session_get_state(sess) == JABBER_IBB_SESSION_NOT_OPENED) {
 		sess->block_size = size;
 	} else {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"Can't set block size on an open IBB session\n");
 	}
 }
@@ -168,30 +168,30 @@
 {
 	sess->opened_cb = cb;
 }
-	
-void 
+
+void
 jabber_ibb_session_set_data_sent_callback(JabberIBBSession *sess,
 	JabberIBBSentCallback *cb)
 {
 	sess->data_sent_cb = cb;
 }
-	
-void 
+
+void
 jabber_ibb_session_set_closed_callback(JabberIBBSession *sess,
 	JabberIBBClosedCallback *cb)
 {
 	sess->closed_cb = cb;
 }
-	
-void 
+
+void
 jabber_ibb_session_set_data_received_callback(JabberIBBSession *sess,
 	JabberIBBDataCallback *cb)
 {
 	sess->data_received_cb = cb;
 }
 
-void 
-jabber_ibb_session_set_error_callback(JabberIBBSession *sess, 
+void
+jabber_ibb_session_set_error_callback(JabberIBBSession *sess,
 	JabberIBBErrorCallback *cb)
 {
 	sess->error_cb = cb;
@@ -207,7 +207,7 @@
 	} else {
 		sess->state = JABBER_IBB_SESSION_OPENED;
 	}
-		
+
 	if (sess->opened_cb) {
 		sess->opened_cb(sess);
 	}
@@ -217,23 +217,23 @@
 jabber_ibb_session_open(JabberIBBSession *sess)
 {
 	if (jabber_ibb_session_get_state(sess) != JABBER_IBB_SESSION_NOT_OPENED) {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"jabber_ibb_session called on an already open stream\n");
 	} else {
 		JabberIq *set = jabber_iq_new(sess->js, JABBER_IQ_SET);
 		xmlnode *open = xmlnode_new("open");
 		gchar block_size[10];
-		
+
 		xmlnode_set_attrib(set->node, "to", jabber_ibb_session_get_who(sess));
 		xmlnode_set_namespace(open, XEP_0047_NAMESPACE);
 		xmlnode_set_attrib(open, "sid", jabber_ibb_session_get_sid(sess));
-		g_snprintf(block_size, sizeof(block_size), "%" G_GSIZE_FORMAT, 
+		g_snprintf(block_size, sizeof(block_size), "%" G_GSIZE_FORMAT,
 			jabber_ibb_session_get_block_size(sess));
 		xmlnode_set_attrib(open, "block-size", block_size);
 		xmlnode_insert_child(set->node, open);
-		
+
 		jabber_iq_set_callback(set, jabber_ibb_session_opened_cb, sess);
-		
+
 		jabber_iq_send(set);
 	}
 }
@@ -242,7 +242,7 @@
 jabber_ibb_session_close(JabberIBBSession *sess)
 {
 	JabberIBBSessionState state = jabber_ibb_session_get_state(sess);
-	
+
 	if (state != JABBER_IBB_SESSION_OPENED && state != JABBER_IBB_SESSION_ERROR) {
 		purple_debug_error("jabber",
 			"jabber_ibb_session_close called on a session that has not been"
@@ -251,7 +251,7 @@
 		JabberIq *set = jabber_iq_new(jabber_ibb_session_get_js(sess),
 			JABBER_IQ_SET);
 		xmlnode *close = xmlnode_new("close");
-		
+
 		xmlnode_set_attrib(set->node, "to", jabber_ibb_session_get_who(sess));
 		xmlnode_set_namespace(close, XEP_0047_NAMESPACE);
 		xmlnode_set_attrib(close, "sid", jabber_ibb_session_get_sid(sess));
@@ -266,7 +266,7 @@
 {
 	JabberIq *result = jabber_iq_new(jabber_ibb_session_get_js(sess),
 		JABBER_IQ_RESULT);
-	
+
 	xmlnode_set_attrib(result->node, "to", jabber_ibb_session_get_who(sess));
 	jabber_iq_set_id(result, sess->id);
 	jabber_iq_send(result);
@@ -278,18 +278,18 @@
 {
 	JabberIBBSession *sess = (JabberIBBSession *) data;
 	xmlnode *error = xmlnode_get_child(packet, "error");
-	
+
 	if (sess) {
 		/* reset callback */
 		if (sess->last_iq_id) {
 			g_free(sess->last_iq_id);
 			sess->last_iq_id = NULL;
 		}
-		
+
 		if (error) {
 			jabber_ibb_session_close(sess);
 			sess->state = JABBER_IBB_SESSION_ERROR;
-		
+
 			if (sess->error_cb) {
 				sess->error_cb(sess);
 			}
@@ -300,7 +300,7 @@
 		}
 	} else {
 		/* the session has gone away, it was probably cancelled */
-		purple_debug_info("jabber", 
+		purple_debug_info("jabber",
 			"got response from send data, but IBB session is no longer active\n");
 	}
 }
@@ -310,33 +310,33 @@
                              gsize size)
 {
 	JabberIBBSessionState state = jabber_ibb_session_get_state(sess);
-	
+
 	purple_debug_info("jabber", "sending data block of %" G_GSIZE_FORMAT " bytes on IBB stream\n",
 		size);
-	
+
 	if (state != JABBER_IBB_SESSION_OPENED) {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"trying to send data on a non-open IBB session\n");
 	} else if (size > jabber_ibb_session_get_block_size(sess)) {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"trying to send a too large packet in the IBB session\n");
 	} else {
-		JabberIq *set = jabber_iq_new(jabber_ibb_session_get_js(sess), 
+		JabberIq *set = jabber_iq_new(jabber_ibb_session_get_js(sess),
 			JABBER_IQ_SET);
 		xmlnode *data_element = xmlnode_new("data");
 		char *base64 = purple_base64_encode(data, size);
 		char seq[10];
 		g_snprintf(seq, sizeof(seq), "%u", jabber_ibb_session_get_send_seq(sess));
-		
+
 		xmlnode_set_attrib(set->node, "to", jabber_ibb_session_get_who(sess));
 		xmlnode_set_namespace(data_element, XEP_0047_NAMESPACE);
 		xmlnode_set_attrib(data_element, "sid", jabber_ibb_session_get_sid(sess));
 		xmlnode_set_attrib(data_element, "seq", seq);
 		xmlnode_insert_data(data_element, base64, -1);
-		
+
 		xmlnode_insert_child(set->node, data_element);
-	
-		purple_debug_info("jabber", 
+
+		purple_debug_info("jabber",
 			"IBB: setting send <iq/> callback for session %p %s\n", sess,
 			sess->sid);
 		jabber_iq_set_callback(set, jabber_ibb_session_send_acknowledge_cb, sess);
@@ -344,7 +344,7 @@
 		purple_debug_info("jabber", "IBB: set sess->last_iq_id: %s\n",
 			sess->last_iq_id);
 		jabber_iq_send(set);
-		
+
 		g_free(base64);
 		(sess->send_seq)++;
 	}
@@ -356,17 +356,17 @@
 	JabberIq *result = jabber_iq_new(js, JABBER_IQ_ERROR);
 	xmlnode *error = xmlnode_new("error");
 	xmlnode *item_not_found = xmlnode_new("item-not-found");
-	
-	xmlnode_set_namespace(item_not_found, 
+
+	xmlnode_set_namespace(item_not_found,
 		"urn:ietf:params:xml:ns:xmpp-stanzas");
 	xmlnode_set_attrib(error, "code", "440");
 	xmlnode_set_attrib(error, "type", "cancel");
 	jabber_iq_set_id(result, xmlnode_get_attrib(packet, "id"));
-	xmlnode_set_attrib(result->node, "to", 
+	xmlnode_set_attrib(result->node, "to",
 		xmlnode_get_attrib(packet, "from"));
 	xmlnode_insert_child(error, item_not_found);
 	xmlnode_insert_child(result->node, error);
-	
+
 	jabber_iq_send(result);
 }
 
@@ -375,23 +375,23 @@
 {
 	xmlnode *data = xmlnode_get_child_with_namespace(packet, "data",
 		XEP_0047_NAMESPACE);
-	xmlnode *close = xmlnode_get_child_with_namespace(packet, "close", 
+	xmlnode *close = xmlnode_get_child_with_namespace(packet, "close",
 		XEP_0047_NAMESPACE);
 	xmlnode *open = xmlnode_get_child_with_namespace(packet, "open",
 		XEP_0047_NAMESPACE);
-	const gchar *sid = 
-		data ? xmlnode_get_attrib(data, "sid") : 
+	const gchar *sid =
+		data ? xmlnode_get_attrib(data, "sid") :
 			close ? xmlnode_get_attrib(close, "sid") : NULL;
-	JabberIBBSession *sess = 
+	JabberIBBSession *sess =
 		sid ? g_hash_table_lookup(jabber_ibb_sessions, sid) : NULL;
 	const gchar *who = xmlnode_get_attrib(packet, "from");
-	
+
 	if (sess) {
-		
+
 		if (strcmp(who, jabber_ibb_session_get_who(sess)) != 0) {
 			/* the iq comes from a different JID than the remote JID of the
 			  session, ignore it */
-			purple_debug_error("jabber", 
+			purple_debug_error("jabber",
 				"Got IBB iq from wrong JID, ignoring\n");
 		} else if (data) {
 			const gchar *seq_attr = xmlnode_get_attrib(data, "seq");
@@ -402,20 +402,20 @@
 			if (seq_attr && seq == jabber_ibb_session_get_recv_seq(sess)) {
 				/* sequence # is the expected... */
 				JabberIq *result = jabber_iq_new(js, JABBER_IQ_RESULT);
-				
+
 				jabber_iq_set_id(result, xmlnode_get_attrib(packet, "id"));
-				xmlnode_set_attrib(result->node, "to", 
+				xmlnode_set_attrib(result->node, "to",
 					xmlnode_get_attrib(packet, "from"));
-				
+
 				if (sess->data_received_cb) {
 					gchar *base64 = xmlnode_get_data(data);
 					gsize size;
 					gpointer rawdata = purple_base64_decode(base64, &size);
-					
+
 					g_free(base64);
-					
+
 					if (rawdata) {
-						purple_debug_info("jabber", 
+						purple_debug_info("jabber",
 							"got %" G_GSIZE_FORMAT " bytes of data on IBB stream\n",
 							size);
 						if (size > jabber_ibb_session_get_block_size(sess)) {
@@ -426,13 +426,13 @@
 							g_free(rawdata);
 							return;
 						} else {
-							purple_debug_info("jabber", 
+							purple_debug_info("jabber",
 								"calling IBB callback for received data\n");
 							sess->data_received_cb(sess, rawdata, size);
 						}
 						g_free(rawdata);
 					} else {
-						purple_debug_error("jabber", 
+						purple_debug_error("jabber",
 							"IBB: invalid BASE64 data received\n");
 						if (sess->error_cb)
 							sess->error_cb(sess);
@@ -440,15 +440,15 @@
 
 					}
 				}
-				
+
 				(sess->recv_seq)++;
 				jabber_iq_send(result);
-				
+
 			} else {
-				purple_debug_error("jabber", 
+				purple_debug_error("jabber",
 					"Received an out-of-order/invalid IBB packet\n");
 				sess->state = JABBER_IBB_SESSION_ERROR;
-				
+
 				if (sess->error_cb) {
 					sess->error_cb(sess);
 				}
@@ -456,12 +456,12 @@
 		} else if (close) {
 			sess->state = JABBER_IBB_SESSION_CLOSED;
 			purple_debug_info("jabber", "IBB: received close\n");
-			
+
 			if (sess->closed_cb) {
 				purple_debug_info("jabber", "IBB: calling closed handler\n");
 				sess->closed_cb(sess);
 			}
-		
+
 		} else {
 			/* this should never happen */
 			purple_debug_error("jabber", "Received bogus iq for IBB session\n");
@@ -469,15 +469,15 @@
 	} else if (open) {
 		JabberIq *result;
 		const GList *iterator;
-		
+
 		/* run all open handlers registered until one returns true */
-		for (iterator = open_handlers ; iterator ; 
+		for (iterator = open_handlers ; iterator ;
 			 iterator = g_list_next(iterator)) {
 			JabberIBBOpenHandler *handler = iterator->data;
 
 			if (handler(js, packet)) {
 				result = jabber_iq_new(js, JABBER_IQ_RESULT);
-				xmlnode_set_attrib(result->node, "to", 
+				xmlnode_set_attrib(result->node, "to",
 					xmlnode_get_attrib(packet, "from"));
 				jabber_iq_set_id(result, xmlnode_get_attrib(packet, "id"));
 				jabber_iq_send(result);
--- a/libpurple/protocols/jabber/ibb.h	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/ibb.h	Mon Mar 02 06:37:05 2009 +0000
@@ -3,17 +3,17 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU Library General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 #ifndef _PURPLE_JABBER_IBB_H_
 #define _PURPLE_JABBER_IBB_H_
 
@@ -24,7 +24,7 @@
 
 typedef struct _JabberIBBSession JabberIBBSession;
 
-typedef void 
+typedef void
 (JabberIBBDataCallback)(JabberIBBSession *, const gpointer data, gsize size);
 
 typedef void (JabberIBBOpenedCallback)(JabberIBBSession *);
@@ -49,13 +49,13 @@
 	guint16 send_seq;
 	guint16 recv_seq;
 	gsize block_size;
-	
+
 	/* session state */
 	JabberIBBSessionState state;
-	
+
 	/* user data (f.ex. a handle to a PurpleXfer) */
 	gpointer user_data;
-	
+
 	/* callbacks */
 	JabberIBBOpenedCallback *opened_cb;
 	JabberIBBSentCallback *data_sent_cb;
@@ -63,7 +63,7 @@
 	/* callback for receiving data */
 	JabberIBBDataCallback *data_received_cb;
 	JabberIBBErrorCallback *error_cb;
-	
+
 	/* store the last sent IQ (to permit cancel of callback) */
 	gchar *last_iq_id;
 };
--- a/libpurple/protocols/jabber/iq.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/iq.c	Mon Mar 02 06:37:05 2009 +0000
@@ -400,7 +400,7 @@
 		jabber_ibb_parse(js, packet);
 		return;
 	}
-	
+
 	/* If we get here, send the default error reply mandated by XMPP-CORE */
 	if(!strcmp(type, "set") || !strcmp(type, "get")) {
 		JabberIq *iq = jabber_iq_new(js, JABBER_IQ_ERROR);
--- a/libpurple/protocols/jabber/jabber.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/jabber.c	Mon Mar 02 06:37:05 2009 +0000
@@ -184,7 +184,7 @@
 {
 	if(xmlnode_get_child(packet, "starttls")) {
 		if(jabber_process_starttls(js, packet))
-	
+
 			return;
 	} else if(purple_account_get_bool(js->gc->account, "require_tls", FALSE) && !js->gsc) {
 		purple_connection_error_reason (js->gc,
@@ -467,10 +467,10 @@
 
 	if (js->keepalive_timeout == -1) {
 		JabberIq *iq = jabber_iq_new(js, JABBER_IQ_GET);
-		
+
 		xmlnode *ping = xmlnode_new_child(iq->node, "ping");
 		xmlnode_set_namespace(ping, "urn:xmpp:ping");
-		
+
 		js->keepalive_timeout = purple_timeout_add_seconds(120, (GSourceFunc)(jabber_pong_timeout), gc);
 		jabber_iq_set_callback(iq, jabber_pong_cb, NULL);
 		jabber_iq_send(iq);
@@ -578,7 +578,7 @@
 		jabber_send_raw(js, "<?xml version='1.0' ?>", -1);
 	jabber_stream_set_state(js, JABBER_STREAM_INITIALIZING);
 	purple_ssl_input_add(gsc, jabber_recv_cb_ssl, gc);
-	
+
 	/* Tell the app that we're doing encryption */
 	jabber_stream_set_state(js, JABBER_STREAM_INITIALIZING_ENCRYPTION);
 }
@@ -736,14 +736,14 @@
 			_("Invalid XMPP ID"));
 		return;
 	}
-	
+
 	if (!js->user->domain || *(js->user->domain) == '\0') {
 		purple_connection_error_reason (gc,
 			PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 			_("Invalid XMPP ID. Domain must be set."));
 		return;
 	}
-	
+
 	if((my_jb = jabber_buddy_find(js, purple_account_get_username(account), TRUE)))
 		my_jb->subscription |= JABBER_SUB_BOTH;
 
@@ -853,10 +853,10 @@
 		g_free(buf);
 	} else {
 		char *msg = jabber_parse_error(js, packet, NULL);
-		
+
 		if(!msg)
 			msg = g_strdup(_("Unknown Error"));
-		
+
 		purple_notify_error(NULL, _("Unregistration Failed"),
 							_("Unregistration Failed"), msg);
 		g_free(msg);
@@ -899,9 +899,9 @@
 					if (cbdata->who)
 						xmlnode_set_attrib(iq->node,"to",cbdata->who);
 					xmlnode_new_child(query, "remove");
-					
+
 					jabber_iq_set_callback(iq, jabber_unregistration_result_cb, cbdata->who);
-					
+
 					jabber_iq_send(iq);
 					g_free(cbdata);
 					return;
@@ -1031,7 +1031,7 @@
 			return;
 		}
 	}
-	
+
 	if((x = xmlnode_get_child_with_namespace(query, "x", "jabber:x:data"))) {
 		jabber_x_data_request(js, x, jabber_register_x_data_cb, g_strdup(from));
 		return;
@@ -1182,7 +1182,7 @@
 
 void jabber_register_gateway(JabberStream *js, const char *gateway) {
 	JabberIq *iq;
-	
+
 	iq = jabber_iq_new_query(js, JABBER_IQ_GET, "jabber:iq:register");
 	xmlnode_set_attrib(iq->node, "to", gateway);
 	jabber_iq_send(iq);
@@ -1257,7 +1257,7 @@
 	const char *type = xmlnode_get_attrib(packet,"type");
 	if(!strcmp(type,"error")) {
 		char *msg = jabber_parse_error(js, packet, NULL);
-		
+
 		purple_notify_error(js->gc, _("Error unregistering account"),
 							_("Error unregistering account"), msg);
 		g_free(msg);
@@ -1291,7 +1291,7 @@
 void jabber_unregister_account(PurpleAccount *account, PurpleAccountUnregistrationCb cb, void *user_data) {
 	PurpleConnection *gc = purple_account_get_connection(account);
 	JabberStream *js;
-	
+
 	if(gc->state != PURPLE_CONNECTED) {
 		if(gc->state != PURPLE_CONNECTING)
 			jabber_login(account);
@@ -1301,7 +1301,7 @@
 		js->unregistration_user_data = user_data;
 		return;
 	}
-	
+
 	js = gc->proto_data;
 
 	if (js->unregistration) {
@@ -1602,10 +1602,10 @@
 	feat->shortname = g_strdup(shortname);
 	feat->namespace = g_strdup(namespace);
 	feat->is_enabled = cb;
-	
+
 	/* try to remove just in case it already exists in the list */
 	jabber_remove_feature(shortname);
-	
+
 	jabber_features = g_list_append(jabber_features, feat);
 }
 
@@ -1616,7 +1616,7 @@
 		if(!strcmp(feat->shortname, shortname)) {
 			g_free(feat->shortname);
 			g_free(feat->namespace);
-			
+
 			g_free(feature->data);
 			jabber_features = g_list_delete_link(jabber_features, feature);
 			break;
@@ -1853,7 +1853,7 @@
 			"mood", _("Mood"), purple_value_new(PURPLE_TYPE_STRING),
 			"moodtext", _("Mood Text"), purple_value_new(PURPLE_TYPE_STRING),
 			"nick", _("Nickname"), purple_value_new(PURPLE_TYPE_STRING),
-			"buzz", _("Allow Buzz"), buzz_enabled,								 
+			"buzz", _("Allow Buzz"), buzz_enabled,
 			NULL);
 	types = g_list_append(types, type);
 
@@ -1869,7 +1869,7 @@
 			"mood", _("Mood"), purple_value_new(PURPLE_TYPE_STRING),
 			"moodtext", _("Mood Text"), purple_value_new(PURPLE_TYPE_STRING),
 			"nick", _("Nickname"), purple_value_new(PURPLE_TYPE_STRING),
-			"buzz", _("Allow Buzz"), buzz_enabled,								 
+			"buzz", _("Allow Buzz"), buzz_enabled,
 			NULL);
 	types = g_list_append(types, type);
 
@@ -2028,7 +2028,7 @@
 
 	if(js->pep)
 		jabber_pep_init_actions(&m);
-	
+
 	if(js->commands)
 		jabber_adhoc_init_server_commands(js, &m);
 
@@ -2080,7 +2080,7 @@
 	JabberID *jid;
 	JabberBuddy *jb;
 	JabberBuddyResource *jbr;
-	
+
 	if(!(jid = jabber_id_new(who)))
 		return;
 
@@ -2341,7 +2341,7 @@
 	if (!chat || !args || !args[0] || !args[1])
 		return PURPLE_CMD_RET_FAILED;
 
-	if (strcmp(args[1], "owner") != 0 && 
+	if (strcmp(args[1], "owner") != 0 &&
 	    strcmp(args[1], "admin") != 0 &&
 	    strcmp(args[1], "member") != 0 &&
 	    strcmp(args[1], "outcast") != 0 &&
@@ -2471,11 +2471,11 @@
 	JabberBuddy *jb;
 	JabberBuddyResource *jbr;
 	PurpleConnection *gc = js->gc;
-	PurpleBuddy *buddy = 
+	PurpleBuddy *buddy =
 		purple_find_buddy(purple_connection_get_account(gc), username);
-	const gchar *alias = 
+	const gchar *alias =
 		buddy ? purple_buddy_get_contact_alias(buddy) : username;
-	
+
 	if(!username)
 		return FALSE;
 
@@ -2485,18 +2485,18 @@
 			"known about %s."), alias);
 		return FALSE;
 	}
-	
+
 	jbr = jabber_buddy_find_resource(jb, NULL);
 	if (!jbr) {
-		*error = g_strdup_printf(_("Unable to buzz, because %s might be offline."), 
+		*error = g_strdup_printf(_("Unable to buzz, because %s might be offline."),
 			alias);
 		return FALSE;
 	}
-	
+
 	if (jabber_resource_has_capability(jbr, XEP_0224_NAMESPACE)) {
 		xmlnode *buzz, *msg = xmlnode_new("message");
 		gchar *to;
-		
+
 		to = g_strdup_printf("%s/%s", username, jbr->name);
 		xmlnode_set_attrib(msg, "to", to);
 		g_free(to);
@@ -2523,7 +2523,7 @@
 {
 	JabberStream *js = conv->account->gc->proto_data;
 	const gchar *who;
-	
+
 	if (!args || !args[0]) {
 		/* use the buddy from conversation, if it's a one-to-one conversation */
 		if (purple_conversation_get_type(conv) == PURPLE_CONV_TYPE_IM) {
@@ -2534,24 +2534,24 @@
 	} else {
 		who = args[0];
 	}
-	
+
 	if (_jabber_send_buzz(js, who, error)) {
 		const gchar *alias;
 		gchar *str;
 		PurpleBuddy *buddy =
-			purple_find_buddy(purple_connection_get_account(conv->account->gc), 
+			purple_find_buddy(purple_connection_get_account(conv->account->gc),
 				who);
-		
+
 		if (buddy != NULL)
 			alias = purple_buddy_get_contact_alias(buddy);
 		else
 			alias = who;
-		
+
 		str = g_strdup_printf(_("Buzzing %s..."), alias);
-		purple_conversation_write(conv, NULL, str, 
+		purple_conversation_write(conv, NULL, str,
 			PURPLE_MESSAGE_SYSTEM|PURPLE_MESSAGE_NOTIFY, time(NULL));
 		g_free(str);
-		
+
 		return PURPLE_CMD_RET_OK;
 	} else {
 		return PURPLE_CMD_RET_FAILED;
@@ -2669,7 +2669,7 @@
 					  _("ping &lt;jid&gt;:	Ping a user/component/server."),
 					  NULL);
 	purple_cmd_register("buzz", "w", PURPLE_CMD_P_PRPL,
-					  PURPLE_CMD_FLAG_IM | PURPLE_CMD_FLAG_PRPL_ONLY | 
+					  PURPLE_CMD_FLAG_IM | PURPLE_CMD_FLAG_PRPL_ONLY |
 					  PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS,
 					  "prpl-jabber", jabber_cmd_buzz,
 					  _("buzz: Buzz a user to get their attention"), NULL);
--- a/libpurple/protocols/jabber/jabber.h	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/jabber.h	Mon Mar 02 06:37:05 2009 +0000
@@ -203,7 +203,7 @@
 	gboolean unregistration;
 	PurpleAccountUnregistrationCb unregistration_cb;
 	void *unregistration_user_data;
-	
+
 	gboolean vcard_fetched;
 
 	/* does the local server support PEP? */
@@ -211,16 +211,16 @@
 
 	/* Is Buzz enabled? */
 	gboolean allowBuzz;
-	
+
 	/* A list of JabberAdHocCommands supported by the server */
 	GList *commands;
-	
+
 	/* last presence update to check for differences */
 	JabberBuddyState old_state;
 	char *old_msg;
 	int old_priority;
 	char *old_avatarhash;
-	
+
 	/* same for user tune */
 	char *old_artist;
 	char *old_title;
@@ -228,9 +228,9 @@
 	char *old_uri;
 	int old_length;
 	char *old_track;
-	
+
 	char *certificate_CN;
-	
+
 	/* A purple timeout tag for the keepalive */
 	int keepalive_timeout;
 
--- a/libpurple/protocols/jabber/libxmpp.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/libxmpp.c	Mon Mar 02 06:37:05 2009 +0000
@@ -138,7 +138,7 @@
 			     purple_marshal_VOID__POINTER_POINTER, NULL, 2,
 			     purple_value_new(PURPLE_TYPE_SUBTYPE, PURPLE_SUBTYPE_CONNECTION),
 			     purple_value_new_outgoing(PURPLE_TYPE_STRING));
-	
+
 	return TRUE;
 }
 
@@ -147,13 +147,13 @@
 	purple_signal_unregister(plugin, "jabber-receiving-xmlnode");
 
 	purple_signal_unregister(plugin, "jabber-sending-xmlnode");
-	
+
 	purple_signal_unregister(plugin, "jabber-sending-text");
-	
+
 	jabber_data_uninit();
 	jabber_si_uninit();
 	jabber_ibb_uninit();
-	
+
 	return TRUE;
 }
 
@@ -206,30 +206,30 @@
 #endif
 	PurpleAccountUserSplit *split;
 	PurpleAccountOption *option;
-	
+
 	/* Translators: 'domain' is used here in the context of Internet domains, e.g. pidgin.im */
 	split = purple_account_user_split_new(_("Domain"), NULL, '@');
 	purple_account_user_split_set_reverse(split, FALSE);
 	prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-	
+
 	split = purple_account_user_split_new(_("Resource"), NULL, '/');
 	purple_account_user_split_set_reverse(split, FALSE);
 	prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-	
+
 	option = purple_account_option_bool_new(_("Require SSL/TLS"), "require_tls", FALSE);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
 											   option);
-	
+
 	option = purple_account_option_bool_new(_("Force old (port 5223) SSL"), "old_ssl", FALSE);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
 											   option);
-	
+
 	option = purple_account_option_bool_new(
 						_("Allow plaintext auth over unencrypted streams"),
 						"auth_plain_in_clear", FALSE);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
 						   option);
-	
+
 	option = purple_account_option_int_new(_("Connect port"), "port", 5222);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
 						   option);
@@ -275,16 +275,16 @@
 #endif
 #endif
 	jabber_register_commands();
-	
+
 	jabber_iq_init();
 	jabber_pep_init();
-	
+
 	jabber_tune_init();
 	jabber_caps_init();
-	
+
 	jabber_data_init();
-	
-	
+
+
 	jabber_ibb_init();
 	jabber_si_init();
 
--- a/libpurple/protocols/jabber/message.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/message.c	Mon Mar 02 06:37:05 2009 +0000
@@ -118,7 +118,7 @@
 				}
 			}
 			serv_got_typing_stopped(jm->js->gc, from);
-			
+
 		} else {
 			serv_got_typing_stopped(jm->js->gc, from);
 		}
@@ -138,7 +138,7 @@
 				g_free(jbr->thread_id);
 			jbr->thread_id = g_strdup(jbr->thread_id);
 		}
-		
+
 		if (jm->js->googletalk && jm->xhtml == NULL) {
 			char *tmp = jm->body;
 			jm->body = jabber_google_format_to_html(jm->body);
@@ -319,14 +319,14 @@
 	GHashTable *table)
 {
 	xmlnode *child;
-	
+
 	for (child = xmlnode_get_child(message, "img") ; child ;
 		 child = xmlnode_get_next_twin(child)) {
 		const gchar *src = xmlnode_get_attrib(child, "src");
-		
+
 		if (g_str_has_prefix(src, "cid:")) {
 			const gchar *cid = src + 4;
-			
+
 			/* if we haven't "fetched" this yet... */
 			if (!g_hash_table_lookup(table, cid)) {
 				/* take a copy of the cid and let the SmileyRef own it... */
@@ -334,14 +334,14 @@
 				JabberSmileyRef *ref = g_new0(JabberSmileyRef, 1);
 				const gchar *alt = xmlnode_get_attrib(child, "alt");
 				ref->cid = temp_cid;
-				/* if there is no "alt" string, use the cid... 
+				/* if there is no "alt" string, use the cid...
 				 include the entire src, eg. "cid:.." to avoid linkification */
 				if (alt && alt[0] != '\0') {
 					/* workaround for when "alt" is set to the value of the
 					 CID (which Jabbim seems to do), to avoid it showing up
 						 as an mailto: link */
 					if (purple_email_is_valid(alt)) {
-						ref->alt = g_strdup_printf("smiley:%s", alt); 
+						ref->alt = g_strdup_printf("smiley:%s", alt);
 					} else {
 						ref->alt = g_strdup(alt);
 					}
@@ -352,7 +352,7 @@
 			}
 		}
 	}
-		
+
 	for (child = message->child ; child ; child = child->next) {
 		jabber_message_get_refs_from_xmlnode_internal(child, table);
 	}
@@ -363,9 +363,9 @@
 {
 	GList **refs = (GList **) user_data;
 	JabberSmileyRef *ref = (JabberSmileyRef *) value;
-	
+
 	*refs = g_list_append(*refs, ref);
-	
+
 	return TRUE;
 }
 
@@ -374,9 +374,9 @@
 {
 	GList *refs = NULL;
 	GHashTable *unique_refs = g_hash_table_new(g_str_hash, g_str_equal);
-	
+
 	jabber_message_get_refs_from_xmlnode_internal(message, unique_refs);
-	(void) g_hash_table_foreach_steal(unique_refs, 
+	(void) g_hash_table_foreach_steal(unique_refs,
 		jabber_message_get_refs_steal, (gpointer) &refs);
 	g_hash_table_destroy(unique_refs);
 	return refs;
@@ -509,7 +509,7 @@
 
 static void
 jabber_message_send_data_request(JabberStream *js, PurpleConversation *conv,
-								 const gchar *cid, const gchar *who, 
+								 const gchar *cid, const gchar *who,
 								 const gchar *alt)
 {
 	JabberIq *request = jabber_iq_new(js, JABBER_IQ_GET);
@@ -571,7 +571,7 @@
 			char *text = xmlnode_get_data(child);
 			if (!text) {
 				xmlnode *enclosed_text_node;
-				
+
 				if ((enclosed_text_node = xmlnode_get_child(child, "text")))
 					text = xmlnode_get_data(enclosed_text_node);
 			}
@@ -623,7 +623,7 @@
 					smiley_refs = jabber_message_get_refs_from_xmlnode(child);
 					purple_debug_info("jabber", "found %d smileys\n",
 						g_list_length(smiley_refs));
-					
+
 					if (jm->type == JABBER_MESSAGE_GROUPCHAT) {
 						JabberID *jid = jabber_id_new(jm->from);
 						JabberChat *chat = NULL;
@@ -667,7 +667,7 @@
 					const gchar *cid = ref->cid;
 					const gchar *alt = ref->alt;
 
-					purple_debug_info("jabber", 
+					purple_debug_info("jabber",
 						"about to add custom smiley %s to the conv\n", alt);
 					if (purple_conv_custom_smiley_add(conv, alt, "cid", cid,
 						    TRUE)) {
@@ -675,8 +675,8 @@
 								jabber_data_find_remote_by_cid(cid);
 						/* if data is already known, we add write it immediatly */
 						if (data) {
-							purple_debug_info("jabber", 
-								"data is already known\n"); 
+							purple_debug_info("jabber",
+								"data is already known\n");
 							purple_conv_custom_smiley_write(conv, alt,
 								jabber_data_get_data(data),
 								jabber_data_get_size(data));
@@ -901,9 +901,9 @@
 {
 	JabberStream *js = (JabberStream *) gc->proto_data;
 	JabberBuddy *jb;
-	
+
 	if (!js) {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"jabber_conv_support_custom_smileys: could not find stream\n");
 		return FALSE;
 	}
@@ -956,7 +956,7 @@
 
 	if(type)
 		xmlnode_set_attrib(message, "type", type);
- 
+
 	if (jm->id)
 		xmlnode_set_attrib(message, "id", jm->id);
 
@@ -1013,7 +1013,7 @@
 		PurpleConversation *conv =
 			purple_find_conversation_with_account(PURPLE_CONV_TYPE_ANY, jm->to,
 				account);
- 
+
 		if (jabber_conv_support_custom_smileys(jm->js->gc, conv, jm->to)) {
 			GList *found_smileys = jabber_message_xhtml_find_smileys(jm->xhtml);
 
@@ -1028,19 +1028,19 @@
 					const gchar *shortcut = purple_smiley_get_shortcut(smiley);
 					const JabberData *data =
 						jabber_data_find_local_by_alt(shortcut);
-							
+
 					/* the object has not been sent before */
 					if (!data) {
 						PurpleStoredImage *image =
 								purple_smiley_get_stored_image(smiley);
 						const gchar *ext = purple_imgstore_get_extension(image);
 						JabberStream *js = jm->js;
-						
+
 						JabberData *new_data =
 							jabber_data_create_from_data(purple_imgstore_get_data(image),
 								purple_imgstore_get_size(image),
 								jabber_message_get_mimetype_from_ext(ext), js);
-						purple_debug_info("jabber", 
+						purple_debug_info("jabber",
 							"cache local smiley alt = %s, cid = %s\n",
 							shortcut, jabber_data_get_cid(new_data));
 						jabber_data_associate_local(new_data, shortcut);
@@ -1115,7 +1115,7 @@
 	}
 
 	buf = g_strdup_printf("<html xmlns='http://jabber.org/protocol/xhtml-im'><body xmlns='http://www.w3.org/1999/xhtml'>%s</body></html>", msg);
-	
+
 	purple_markup_html_to_xhtml(buf, &xhtml, &jm->body);
 	g_free(buf);
 
--- a/libpurple/protocols/jabber/pep.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/pep.c	Mon Mar 02 06:37:05 2009 +0000
@@ -32,7 +32,7 @@
 void jabber_pep_init(void) {
 	if(!pep_handlers) {
 		pep_handlers = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL);
-		
+
 		/* register PEP handlers */
 		jabber_mood_init();
 		jabber_nick_init();
@@ -57,31 +57,31 @@
 	xmlnode *pubsub = xmlnode_get_child_with_namespace(packet,"pubsub","http://jabber.org/protocol/pubsub");
 	xmlnode *items = NULL;
 	JabberPEPHandler *cb = data;
-	
+
 	if(pubsub)
 		items = xmlnode_get_child(pubsub, "items");
-	
+
 	cb(js, from, items);
 }
 
 void jabber_pep_request_item(JabberStream *js, const char *to, const char *node, const char *id, JabberPEPHandler cb) {
 	JabberIq *iq = jabber_iq_new(js, JABBER_IQ_GET);
 	xmlnode *pubsub, *items, *item;
-	
+
 	xmlnode_set_attrib(iq->node,"to",to);
 	pubsub = xmlnode_new_child(iq->node,"pubsub");
-	
+
 	xmlnode_set_namespace(pubsub,"http://jabber.org/protocol/pubsub");
-	
+
 	items = xmlnode_new_child(pubsub, "items");
 	xmlnode_set_attrib(items,"node",node);
-	
+
 	item = xmlnode_new_child(items, "item");
 	if(id)
 		xmlnode_set_attrib(item, "id", id);
-	
+
 	jabber_iq_set_callback(iq,do_pep_iq_request_item_callback,(gpointer)cb);
-	
+
 	jabber_iq_send(iq);
 }
 
@@ -94,15 +94,15 @@
 	JabberPEPHandler *jph;
 	GList *itemslist;
 	char *jid = jabber_get_bare_jid(jm->from);
-	
+
 	for(itemslist = jm->eventitems; itemslist; itemslist = itemslist->next) {
 		xmlnode *items = (xmlnode*)itemslist->data;
 		const char *nodename = xmlnode_get_attrib(items,"node");
-		
+
 		if(nodename && (jph = g_hash_table_lookup(pep_handlers, nodename)))
 			jph(jm->js, jid, items);
 	}
-	
+
 	/* discard items we don't have a handler for */
 	g_free(jid);
 }
--- a/libpurple/protocols/jabber/presence.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/presence.c	Mon Mar 02 06:37:05 2009 +0000
@@ -136,7 +136,7 @@
 	}
 
 	purple_status_to_jabber(status, &state, &stripped, &priority);
-	
+
 	/* check for buzz support */
 	allowBuzz = purple_status_get_attr_boolean(status,"buzz");
 	/* changing the buzz state has to trigger a re-broadcasting of the presence for caps */
@@ -145,7 +145,7 @@
 		tune = purple_presence_get_status(p, "tune");
 		stripped = jabber_google_presence_outgoing(tune);
 	}
-	
+
 #define CHANGED(a,b) ((!a && b) || (a && a[0] == '\0' && b && b[0] != '\0') || \
 					  (a && !b) || (a && a[0] != '\0' && b && b[0] == '\0') || (a && b && strcmp(a,b)))
 	/* check if there are any differences to the <presence> and send them in that case */
@@ -166,9 +166,9 @@
 
 		g_hash_table_foreach(js->chats, chats_send_presence_foreach, presence);
 		xmlnode_free(presence);
-		
+
 		/* update old values */
-		
+
 		if(js->old_msg)
 			g_free(js->old_msg);
 		if(js->old_avatarhash)
@@ -191,7 +191,7 @@
 		length = (!purple_status_get_attr_value(tune, PURPLE_TUNE_TIME)) ? -1 :
 				purple_status_get_attr_int(tune, PURPLE_TUNE_TIME);
 	}
-	
+
 	if(CHANGED(artist, js->old_artist) || CHANGED(title, js->old_title) || CHANGED(source, js->old_source) ||
 	   CHANGED(uri, js->old_uri) || CHANGED(track, js->old_track) || (length != js->old_length)) {
 		PurpleJabberTuneInfo tuneinfo = {
@@ -203,7 +203,7 @@
 			(char*)uri
 		};
 		jabber_tune_set(js->gc, &tuneinfo);
-		
+
 		/* update old values */
 		g_free(js->old_artist);
 		g_free(js->old_title);
@@ -264,27 +264,27 @@
 	xmlnode_set_namespace(c, "http://jabber.org/protocol/caps");
 	xmlnode_set_attrib(c, "node", CAPS0115_NODE);
 	xmlnode_set_attrib(c, "ver", VERSION);
-	
+
 	if(js != NULL) {
 		/* add the extensions */
 		char extlist[1024];
 		unsigned remaining = 1023; /* one less for the \0 */
 		GList *feature;
-		
+
 		extlist[0] = '\0';
 		for(feature = jabber_features; feature && remaining > 0; feature = feature->next) {
 			JabberFeature *feat = (JabberFeature*)feature->data;
 			unsigned featlen;
-			
+
 			if(feat->is_enabled != NULL && feat->is_enabled(js, feat->shortname, feat->namespace) == FALSE)
 				continue; /* skip this feature */
-			
+
 			featlen = strlen(feat->shortname);
-			
+
 			/* cut off when we don't have any more space left in our buffer (too bad) */
 			if(featlen > remaining)
 				break;
-			
+
 			strncat(extlist,feat->shortname,remaining);
 			remaining -= featlen;
 			if(feature->next) { /* no space at the end */
@@ -296,7 +296,7 @@
 		if(remaining < 1023)
 			xmlnode_set_attrib(c, "ext", extlist);
 	}
-	
+
 	return presence;
 }
 
@@ -745,7 +745,7 @@
 				const char *node = xmlnode_get_attrib(caps,"node");
 				const char *ver = xmlnode_get_attrib(caps,"ver");
 				const char *ext = xmlnode_get_attrib(caps,"ext");
-				
+
 				if(node && ver) {
 					JabberPresenceCapabilities *userdata = g_new0(JabberPresenceCapabilities, 1);
 					userdata->js = js;
--- a/libpurple/protocols/jabber/roster.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/roster.c	Mon Mar 02 06:37:05 2009 +0000
@@ -105,7 +105,7 @@
 		if (pool) {
 			b = pool->data;
 			pool = g_list_delete_link(pool, pool);
-		} else {			
+		} else {
 			b = purple_buddy_new(js->gc->account, jid, alias);
 		}
 
@@ -315,7 +315,7 @@
 
 	if(!grps)
 		g_slist_free(groups);
-	
+
 	if (js->server_caps & JABBER_CAP_GOOGLE_ROSTER) {
 		jabber_google_roster_outgoing(js, query, item);
 		xmlnode_set_attrib(query, "xmlns:gr", "google:roster");
--- a/libpurple/protocols/jabber/si.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/si.c	Mon Mar 02 06:37:05 2009 +0000
@@ -64,7 +64,7 @@
 	size_t rxlen;
 	gsize rxmaxlen;
 	int local_streamhost_fd;
-	
+
 	JabberIBBSession *ibb_session;
 	guint ibb_timeout_handle;
 	FILE *fp;
@@ -200,15 +200,15 @@
 {
 	PurpleXfer *xfer = (PurpleXfer *) data;
 	JabberSIXfer *jsx = xfer->data;
-	
+
 	if (jsx && !jsx->ibb_session) {
-		purple_debug_info("jabber", 
+		purple_debug_info("jabber",
 			"jabber_si_bytestreams_ibb_timeout called and IBB session not set "
 			" up yet, cancel transfer");
 		jabber_si_bytestreams_ibb_timeout_remove(jsx);
 		purple_xfer_cancel_local(xfer);
 	}
-	
+
 	return FALSE;
 }
 
@@ -237,7 +237,7 @@
 		/* if IBB is available, revert to that before giving up... */
 		if (jsx->stream_method & STREAM_METHOD_IBB) {
 			/* if we are the initializer, init IBB */
-			purple_debug_info("jabber", 
+			purple_debug_info("jabber",
 				"jabber_si_bytestreams_attempt_connect: "
 				"no streamhosts found, trying IBB\n");
 			/* if we are the sender, open an IBB session, but not if we already
@@ -248,7 +248,7 @@
 				jabber_si_xfer_ibb_send_init(jsx->js, xfer);
 			} else {
 				/* setup a timeout to cancel waiting for IBB open */
-				jsx->ibb_timeout_handle = purple_timeout_add_seconds(30, 
+				jsx->ibb_timeout_handle = purple_timeout_add_seconds(30,
 					jabber_si_bytestreams_ibb_timeout_cb, xfer);
 			}
 			/* if we are the receiver, just wait for IBB open, callback is
@@ -256,7 +256,7 @@
 		} else {
 			purple_xfer_cancel_local(xfer);
 		}
-		
+
 		return;
 	}
 
@@ -709,12 +709,12 @@
 	jsx = xfer->data;
 
 	if(!(type = xmlnode_get_attrib(packet, "type")) || strcmp(type, "result")) {
-	  purple_debug_info("jabber", 
+	  purple_debug_info("jabber",
 			    "jabber_si_xfer_connect_proxy_cb: type = %s\n",
 			    type);
 		if (type && !strcmp(type, "error")) {
 			/* if IBB is available, open IBB session */
-			purple_debug_info("jabber", 
+			purple_debug_info("jabber",
 				"jabber_si_xfer_connect_proxy_cb: got error, method: %d\n",
 				jsx->stream_method);
 			if (jsx->stream_method & STREAM_METHOD_IBB) {
@@ -763,7 +763,7 @@
 		} else {
 			/* if available, try to revert to IBB... */
 			if (jsx->stream_method & STREAM_METHOD_IBB) {
-				purple_debug_info("jabber", 
+				purple_debug_info("jabber",
 					"jabber_si_connect_proxy_cb: trying to revert to IBB\n");
 				if (purple_xfer_get_type(xfer) == PURPLE_XFER_SEND) {
 					jabber_si_xfer_ibb_send_init(jsx->js, xfer);
@@ -773,7 +773,7 @@
 				}
 				/* if we are the receiver, we are already set up...*/
 			} else {
-				purple_debug_info("jabber", 
+				purple_debug_info("jabber",
 					"streamhost-used does not match any proxy that was offered to target\n");
 				purple_xfer_cancel_local(xfer);
 			}
@@ -903,7 +903,7 @@
 	/* We have no way of transferring, cancel the transfer */
 	if (streamhost_count == 0) {
 		jabber_iq_free(iq);
-		
+
 		/* if available, revert to IBB */
 		if (jsx->stream_method & STREAM_METHOD_IBB) {
 			purple_debug_info("jabber",
@@ -918,11 +918,11 @@
 			/* if we are the receiver, we should just wait... the IBB open
 			  handler has already been set up... */
 		} else {
-			/* We should probably notify the target, 
+			/* We should probably notify the target,
 			  but this really shouldn't ever happen */
 			purple_xfer_cancel_local(xfer);
 		}
-		
+
 		return;
 	}
 
@@ -959,10 +959,10 @@
 	JabberStream *js = jabber_ibb_session_get_js(sess);
 	PurpleConnection *gc = js->gc;
 	PurpleAccount *account = purple_connection_get_account(gc);
-	
+
 	purple_debug_error("jabber", "an error occured during IBB file transfer\n");
 	purple_xfer_error(purple_xfer_get_type(xfer), account,
-		jabber_ibb_session_get_who(sess), 
+		jabber_ibb_session_get_who(sess),
 			_("An error occured on the in-band bytestream transfer\n"));
 	purple_xfer_cancel_remote(xfer);
 }
@@ -974,7 +974,7 @@
 	JabberStream *js = jabber_ibb_session_get_js(sess);
 	PurpleConnection *gc = js->gc;
 	PurpleAccount *account = purple_connection_get_account(gc);
-	
+
 	purple_debug_info("jabber", "the remote user closed the transfer\n");
 	if (purple_xfer_get_bytes_remaining(xfer) > 0) {
 		purple_xfer_error(purple_xfer_get_type(xfer), account,
@@ -992,7 +992,7 @@
 {
 	PurpleXfer *xfer = (PurpleXfer *) jabber_ibb_session_get_user_data(sess);
 	JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-	
+
 	if (size <= purple_xfer_get_bytes_remaining(xfer)) {
 		purple_debug_info("jabber", "about to write %" G_GSIZE_FORMAT " bytes from IBB stream\n",
 			size);
@@ -1003,7 +1003,7 @@
 		}
 		purple_xfer_set_bytes_sent(xfer, purple_xfer_get_bytes_sent(xfer) + size);
 		purple_xfer_update_progress(xfer);
-		
+
 		if (purple_xfer_get_bytes_remaining(xfer) == 0) {
 			purple_xfer_set_completed(xfer, TRUE);
 			purple_xfer_end(xfer);
@@ -1011,11 +1011,11 @@
 	} else {
 		/* trying to write past size of file transfers negotiated size,
 		  reject transfer to protect against malicious behaviour */
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"IBB file transfer send more data than expected\n");
 		purple_xfer_cancel_remote(xfer);
 	}
-	
+
 }
 
 static gboolean
@@ -1027,7 +1027,7 @@
 	PurpleXfer *xfer = jabber_si_xfer_find(js, sid, who);
 	if (xfer) {
 		JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-		JabberIBBSession *sess = 
+		JabberIBBSession *sess =
 			jabber_ibb_session_create_from_xmlnode(js, packet, xfer);
 		const char *filename;
 
@@ -1047,13 +1047,13 @@
 			/* setup callbacks here...*/
 			jabber_ibb_session_set_data_received_callback(sess,
 				jabber_si_xfer_ibb_recv_data_cb);
-			jabber_ibb_session_set_closed_callback(sess, 
+			jabber_ibb_session_set_closed_callback(sess,
 				jabber_si_xfer_ibb_closed_cb);
 			jabber_ibb_session_set_error_callback(sess,
 				jabber_si_xfer_ibb_error_cb);
-			
+
 			jsx->ibb_session = sess;
-			
+
 			/* start the transfer */
 			purple_xfer_start(xfer, 0, NULL, 0);
 			return TRUE;
@@ -1065,12 +1065,12 @@
 		}
 	} else {
 		/* we got an IBB <open/> for an unknown file transfer, pass along... */
-		purple_debug_info("jabber", 
+		purple_debug_info("jabber",
 			"IBB open did not match any SI file transfer\n");
 		return FALSE;
 	}
 }
-															
+
 static void
 jabber_si_xfer_ibb_send_data(JabberIBBSession *sess)
 {
@@ -1081,18 +1081,18 @@
 		remaining : jabber_ibb_session_get_block_size(sess);
 	gpointer data = g_malloc(packet_size);
 	int res;
-	
+
 	purple_debug_info("jabber", "IBB: about to read %" G_GSIZE_FORMAT " bytes from file %p\n",
 		packet_size, jsx->fp);
 	res = fread(data, packet_size, 1, jsx->fp);
-	
+
 	if (res == 1) {
 		jabber_ibb_session_send_data(sess, data, packet_size);
-		purple_xfer_set_bytes_sent(xfer, 
+		purple_xfer_set_bytes_sent(xfer,
 			purple_xfer_get_bytes_sent(xfer) + packet_size);
 		purple_xfer_update_progress(xfer);
 	} else {
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"jabber_si_xfer_ibb_send_data: error reading from file\n");
 		purple_xfer_cancel_local(xfer);
 	}
@@ -1103,7 +1103,7 @@
 {
 	PurpleXfer *xfer = (PurpleXfer *) jabber_ibb_session_get_user_data(sess);
 	gsize remaining = purple_xfer_get_bytes_remaining(xfer);
-	
+
 	if (remaining == 0) {
 		/* close the session */
 		jabber_ibb_session_close(sess);
@@ -1144,7 +1144,7 @@
 	} else {
 		/* error */
 		purple_xfer_error(purple_xfer_get_type(xfer), account,
-			jabber_ibb_session_get_who(sess), 
+			jabber_ibb_session_get_who(sess),
 			_("Failed to open in-band bytestream"));
 		purple_xfer_end(xfer);
 	}
@@ -1154,12 +1154,12 @@
 jabber_si_xfer_ibb_send_init(JabberStream *js, PurpleXfer *xfer)
 {
 	JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-	
+
 	purple_xfer_ref(xfer);
-	
+
 	jsx->ibb_session = jabber_ibb_session_create(js, jsx->stream_id,
 		purple_xfer_get_remote_user(xfer), xfer);
-	
+
 	if (jsx->ibb_session) {
 		/* should set callbacks here... */
 		jabber_ibb_session_set_opened_callback(jsx->ibb_session,
@@ -1170,18 +1170,18 @@
 			jabber_si_xfer_ibb_closed_cb);
 		jabber_ibb_session_set_error_callback(jsx->ibb_session,
 			jabber_si_xfer_ibb_error_cb);
-		
+
 		/* open the IBB session */
 		jabber_ibb_session_open(jsx->ibb_session);
-		
+
 	} else {
 		/* failed to create IBB session */
-		purple_debug_error("jabber", 
+		purple_debug_error("jabber",
 			"failed to initiate IBB session for file transfer\n");
 		purple_xfer_cancel_local(xfer);
 	}
 }
-	
+
 static void jabber_si_xfer_send_method_cb(JabberStream *js, xmlnode *packet,
 		gpointer data)
 {
@@ -1207,7 +1207,7 @@
 	for(field = xmlnode_get_child(x, "field"); field; field = xmlnode_get_next_twin(field)) {
 		const char *var = xmlnode_get_attrib(field, "var");
 		JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-		
+
 		if(var && !strcmp(var, "stream-method")) {
 			if((value = xmlnode_get_child(field, "value"))) {
 				char *val = xmlnode_get_data(value);
@@ -1228,11 +1228,11 @@
 			}
 		}
 	}
-	
+
 	if (!found_method) {
 		purple_xfer_cancel_remote(xfer);
 	}
-	
+
 }
 
 static void jabber_si_xfer_send_request(PurpleXfer *xfer)
@@ -1290,12 +1290,12 @@
 static void jabber_si_xfer_free(PurpleXfer *xfer)
 {
 	JabberSIXfer *jsx = xfer->data;
-	
+
 	if (jsx) {
 		JabberStream *js = jsx->js;
-		
+
 		js->file_transfers = g_list_remove(js->file_transfers, xfer);
-	
+
 		if (jsx->connect_data != NULL)
 			purple_proxy_connect_cancel(jsx->connect_data);
 		if (jsx->listen_data != NULL)
@@ -1308,24 +1308,24 @@
 			purple_timeout_remove(jsx->connect_timeout);
 		if (jsx->ibb_timeout_handle > 0)
 			purple_timeout_remove(jsx->ibb_timeout_handle);
-		
+
 		if (jsx->streamhosts) {
 			g_list_foreach(jsx->streamhosts, jabber_si_free_streamhost, NULL);
 			g_list_free(jsx->streamhosts);
 		}
-	
+
 		if (jsx->ibb_session) {
-			purple_debug_info("jabber", 
+			purple_debug_info("jabber",
 				"jabber_si_xfer_free: destroying IBB session\n");
 			jabber_ibb_session_destroy(jsx->ibb_session);
 		}
-		
+
 		if (jsx->fp) {
-			purple_debug_info("jabber", 
+			purple_debug_info("jabber",
 				"jabber_si_xfer_free: closing file for IBB transfer\n");
 			fclose(jsx->fp);
 		}
-	
+
 		g_free(jsx->stream_id);
 		g_free(jsx->iq_id);
 		/* XXX: free other stuff */
@@ -1336,7 +1336,7 @@
 		purple_debug_info("jabber", "jabber_si_xfer_free(): freeing jsx %p\n", jsx);
 	}
 }
-		
+
 /*
  * These four functions should only be called from the PurpleXfer functions
  * (typically purple_xfer_cancel_(remote|local), purple_xfer_end, or
@@ -1345,7 +1345,7 @@
 static void jabber_si_xfer_cancel_send(PurpleXfer *xfer)
 {
 	JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-	
+
 	/* if there is an IBB session active, send close on that */
 	if (jsx->ibb_session) {
 		jabber_ibb_session_close(jsx->ibb_session);
@@ -1385,9 +1385,9 @@
 {
 	PurpleXfer *xfer = (PurpleXfer *) data;
 	JabberSIXfer *jsx = (JabberSIXfer *) xfer->data;
-	
+
 	if (capabilities & JABBER_CAP_IBB) {
-		purple_debug_info("jabber", 
+		purple_debug_info("jabber",
 			"jabber_si_xfer_send_disco_cb: remote JID supports IBB\n");
 		jsx->stream_method |= STREAM_METHOD_IBB;
 	}
@@ -1521,7 +1521,7 @@
 		xmlnode_set_attrib(x, "type", "submit");
 		field = xmlnode_new_child(x, "field");
 		xmlnode_set_attrib(field, "var", "stream-method");
-					
+
 		/* we should maybe "remember" if bytestreams has failed before (in the
 			same session) with this JID, and only present IBB as an option to
 			avoid unnessesary timeout */
@@ -1534,7 +1534,7 @@
 			value = xmlnode_new_child(field, "value");
 			xmlnode_insert_data(value, "http://jabber.org/protocol/ibb", -1);
 		}
-							  
+
 		jabber_iq_send(iq);
 	}
 }
@@ -1554,7 +1554,7 @@
 		xfer->data = jsx = g_new0(JabberSIXfer, 1);
 		jsx->js = js;
 		jsx->local_streamhost_fd = -1;
-		
+
 		jsx->ibb_session = NULL;
 		jsx->fp = NULL;
 
@@ -1628,7 +1628,7 @@
 
 	jsx = g_new0(JabberSIXfer, 1);
 	jsx->local_streamhost_fd = -1;
-				   
+
 	jsx->ibb_session = NULL;
 
 	for(field = xmlnode_get_child(x, "field"); field; field = xmlnode_get_next_twin(field)) {
--- a/libpurple/protocols/jabber/usermood.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/usermood.c	Mon Mar 02 06:37:05 2009 +0000
@@ -103,7 +103,7 @@
 	/* ignore the mood of people not on our buddy list */
 	if (!buddy || !item)
 		return;
-	
+
 	mood = xmlnode_get_child_with_namespace(item, "mood", "http://jabber.org/protocol/mood");
 	if (!mood)
 		return;
@@ -179,10 +179,10 @@
 
 	field = purple_request_field_choice_new("mood",
 											_("Mood"), 0);
-	
+
 	for(i = 0; moodstrings[i]; ++i)
 		purple_request_field_choice_add(field, _(moodstrings[i]));
-	
+
 	purple_request_field_set_required(field, TRUE);
 	purple_request_field_group_add_field(group, field);
 
@@ -190,7 +190,7 @@
 											_("Description"), NULL,
 											FALSE);
 	purple_request_field_group_add_field(group, field);
-	
+
 	purple_request_fields(gc, _("Edit User Mood"),
 						  _("Edit User Mood"),
 						  _("Please select your mood from the list."),
@@ -199,7 +199,7 @@
 						  _("Cancel"), NULL,
 						  purple_connection_get_account(gc), NULL, NULL,
 						  gc);
-	
+
 }
 
 void jabber_mood_init_action(GList **m) {
@@ -222,7 +222,7 @@
 		xmlnode *textnode = xmlnode_new_child(moodnode, "text");
 		xmlnode_insert_data(textnode, text, -1);
 	}
-	
+
 	jabber_pep_publish(js, publish);
 	/* publish is freed by jabber_pep_publish -> jabber_iq_send -> jabber_iq_free
 	   (yay for well-defined memory management rules) */
--- a/libpurple/protocols/jabber/usernick.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/usernick.c	Mon Mar 02 06:37:05 2009 +0000
@@ -34,11 +34,11 @@
 	JabberBuddy *buddy = jabber_buddy_find(js, from, FALSE);
 	xmlnode *nick;
 	char *nickname = NULL;
-	
+
 	/* ignore the tune of people not on our buddy list */
 	if (!buddy || !item)
 		return;
-	
+
 	nick = xmlnode_get_child_with_namespace(item, "nick", "http://jabber.org/protocol/nick");
 	if (!nick)
 		return;
@@ -49,15 +49,15 @@
 
 static void do_nick_set(JabberStream *js, const char *nick) {
 	xmlnode *publish, *nicknode;
-	
+
 	publish = xmlnode_new("publish");
 	xmlnode_set_attrib(publish,"node","http://jabber.org/protocol/nick");
 	nicknode = xmlnode_new_child(xmlnode_new_child(publish, "item"), "nick");
 	xmlnode_set_namespace(nicknode, "http://jabber.org/protocol/nick");
-	
+
 	if(nick && nick[0] != '\0')
 		xmlnode_insert_data(nicknode, nick, -1);
-	
+
 	jabber_pep_publish(js, publish);
 	/* publish is freed by jabber_pep_publish -> jabber_iq_send -> jabber_iq_free
 		(yay for well-defined memory management rules) */
@@ -66,13 +66,13 @@
 static void do_nick_got_own_nick_cb(JabberStream *js, const char *from, xmlnode *items) {
 	char *oldnickname = NULL;
 	xmlnode *item = xmlnode_get_child(items,"item");
-	
+
 	if(item) {
 		xmlnode *nick = xmlnode_get_child_with_namespace(item,"nick","http://jabber.org/protocol/nick");
 		if(nick)
 			oldnickname = xmlnode_get_data(nick);
 	}
-	
+
 	purple_request_input(js->gc, _("Set User Nickname"), _("Please specify a new nickname for you."),
 		_("This information is visible to all contacts on your contact list, so choose something appropriate."),
 		oldnickname, FALSE, FALSE, NULL, _("Set"), PURPLE_CALLBACK(do_nick_set), _("Cancel"), NULL,
@@ -84,7 +84,7 @@
 	PurpleConnection *gc = (PurpleConnection *) action->context;
 	JabberStream *js = gc->proto_data;
 	char *jid = g_strdup_printf("%s@%s", js->user->node, js->user->domain);
-	
+
 	/* since the nickname might have been changed by another resource of this account, we always have to request the old one
 		from the server to present as the default for the new one */
 	jabber_pep_request_item(js, jid, "http://jabber.org/protocol/nick", NULL, do_nick_got_own_nick_cb);
--- a/libpurple/protocols/jabber/usertune.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/usertune.c	Mon Mar 02 06:37:05 2009 +0000
@@ -116,12 +116,12 @@
 void jabber_tune_set(PurpleConnection *gc, const PurpleJabberTuneInfo *tuneinfo) {
 	xmlnode *publish, *tunenode;
 	JabberStream *js = gc->proto_data;
-	
+
 	publish = xmlnode_new("publish");
 	xmlnode_set_attrib(publish,"node","http://jabber.org/protocol/tune");
 	tunenode = xmlnode_new_child(xmlnode_new_child(publish, "item"), "tune");
 	xmlnode_set_namespace(tunenode, "http://jabber.org/protocol/tune");
-	
+
 	if(tuneinfo) {
 		if(tuneinfo->artist && tuneinfo->artist[0] != '\0')
 			xmlnode_insert_data(xmlnode_new_child(tunenode, "artist"),tuneinfo->artist,-1);
@@ -139,7 +139,7 @@
 		if(tuneinfo->track && tuneinfo->track[0] != '\0')
 			xmlnode_insert_data(xmlnode_new_child(tunenode, "track"),tuneinfo->track,-1);
 	}
-	
+
 	jabber_pep_publish(js, publish);
 	/* publish is freed by jabber_pep_publish -> jabber_iq_send -> jabber_iq_free
 	   (yay for well-defined memory management rules) */
--- a/libpurple/protocols/jabber/xdata.c	Mon Mar 02 06:26:15 2009 +0000
+++ b/libpurple/protocols/jabber/xdata.c	Mon Mar 02 06:37:05 2009 +0000
@@ -372,7 +372,7 @@
 		if(field && xmlnode_get_child(fn, "required"))
 			purple_request_field_set_required(field,TRUE);
 	}
-	
+
 	if(actions != NULL) {
 		PurpleRequestField *actionfield;
 		GList *action;
@@ -382,7 +382,7 @@
 
 		for(action = actions; action; action = g_list_next(action)) {
 			JabberXDataAction *a = action->data;
-			
+
 			purple_request_field_choice_add(actionfield, a->name);
 			data->actions = g_list_append(data->actions, g_strdup(a->handle));
 		}