pidgin: 85d6ddcc: More uniformity among disconnect error m...

markdoliner at pidgin.im markdoliner at pidgin.im
Mon Jul 6 05:16:01 EDT 2009


-----------------------------------------------------------------
Revision: 85d6ddccd30dc452a4afcd6adc18d9369901b646
Ancestor: 03abb08a3ea6fd140125eeb94b3c7992f217fd6d
Author: markdoliner at pidgin.im
Date: 2009-07-06T09:07:42
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/85d6ddccd30dc452a4afcd6adc18d9369901b646

Modified files:
        libpurple/protocols/irc/dcc_send.c
        libpurple/protocols/irc/irc.c
        libpurple/protocols/jabber/auth.c
        libpurple/protocols/jabber/bosh.c
        libpurple/protocols/jabber/jabber.c
        libpurple/protocols/msn/msn.c
        libpurple/protocols/msn/session.c
        libpurple/protocols/msnp9/msn.c
        libpurple/protocols/msnp9/session.c
        libpurple/protocols/myspace/myspace.c
        libpurple/protocols/myspace/user.c
        libpurple/protocols/novell/novell.c
        libpurple/protocols/oscar/clientlogin.c
        libpurple/protocols/oscar/flap_connection.c
        libpurple/protocols/oscar/odc.c
        libpurple/protocols/oscar/oscar.c
        libpurple/protocols/qq/qq_base.c
        libpurple/protocols/qq/qq_network.c
        libpurple/protocols/qq/qq_process.c
        libpurple/protocols/sametime/sametime.c
        libpurple/protocols/silc/ops.c
        libpurple/protocols/silc/silc.c
        libpurple/protocols/silc/util.c
        libpurple/protocols/silc10/ops.c
        libpurple/protocols/silc10/silc.c
        libpurple/protocols/simple/simple.c
        libpurple/protocols/yahoo/yahoo.c
        libpurple/protocols/yahoo/ycht.c libpurple/proxy.c

ChangeLog: 

More uniformity among disconnect error messages

-------------- next part --------------
============================================================
--- libpurple/protocols/irc/dcc_send.c	1717c04e29aae322df55a46ef6f809728cff18ca
+++ libpurple/protocols/irc/dcc_send.c	a074899e6b9ed2971fa318d714dfae9b3365a4df
@@ -302,7 +302,7 @@ irc_dccsend_network_listen_cb(int sock, 
 
 	if (sock < 0) {
 		purple_notify_error(gc, NULL, _("File Transfer Failed"),
-		                    _("Could not open a listening port."));
+		                    _("Unable to open a listening port."));
 		purple_xfer_cancel_local(xfer);
 		return;
 	}
@@ -343,7 +343,7 @@ static void irc_dccsend_send_init(Purple
 	if (xd->listen_data == NULL) {
 		purple_xfer_unref(xfer);
 		purple_notify_error(gc, NULL, _("File Transfer Failed"),
-		                    _("Could not open a listening port."));
+		                    _("Unable to open a listening port."));
 		purple_xfer_cancel_local(xfer);
 	}
 
============================================================
--- libpurple/protocols/irc/irc.c	06ad65b86e4e1416ecde36e62723799c85900319
+++ libpurple/protocols/irc/irc.c	a02796a2798a16a8dd2606252755cf3ba56a1a3c
@@ -354,7 +354,7 @@ static void irc_login(PurpleAccount *acc
 		{
 			purple_connection_error_reason (gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Unable to create socket"));
+				_("Unable to connect"));
 			return;
 		}
 	}
============================================================
--- libpurple/protocols/jabber/auth.c	40d953c8c93961a96aa42fd7147a99718bee5f18
+++ libpurple/protocols/jabber/auth.c	2f6f575b7aebdd62699db78f9c7ff1e1ce8c79c5
@@ -52,12 +52,12 @@ jabber_process_starttls(JabberStream *js
 					"<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>", -1);
 			return TRUE;
 		} else if(xmlnode_get_child(starttls, "required")) {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 				_("Server requires TLS/SSL, but no TLS/SSL support was found."));
 			return TRUE;
 		} else if(purple_account_get_bool(js->gc->account, "require_tls", FALSE)) {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				 PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 				_("You require encryption, but no TLS/SSL support was found."));
 			return TRUE;
@@ -122,7 +122,7 @@ static void disallow_plaintext_auth(Purp
 
 static void disallow_plaintext_auth(PurpleAccount *account)
 {
-	purple_connection_error_reason (account->gc,
+	purple_connection_error_reason(account->gc,
 		PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
 		_("Server requires plaintext authentication over an unencrypted stream"));
 }
@@ -415,7 +415,7 @@ static void jabber_auth_start_cyrus(Jabb
 		jabber_send(js, auth);
 		xmlnode_free(auth);
 	} else {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE,
 			_("SASL authentication failed"));
 	}
@@ -490,9 +490,9 @@ jabber_auth_start(JabberStream *js, xmln
 	mechs = xmlnode_get_child(packet, "mechanisms");
 
 	if(!mechs) {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Invalid response from server."));
+			_("Invalid response from server"));
 		return;
 	}
 
@@ -561,7 +561,7 @@ jabber_auth_start(JabberStream *js, xmln
 		}
 		finish_plaintext_authentication(js);
 	} else {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE,
 				_("Server does not use any supported authentication method"));
 	}
@@ -590,7 +590,7 @@ static void auth_old_result_cb(JabberStr
 				purple_account_set_password(js->gc->account, NULL);
 		}
 
-		purple_connection_error_reason (js->gc, reason, msg);
+		purple_connection_error_reason(js->gc, reason, msg);
 		g_free(msg);
 	}
 }
@@ -606,7 +606,7 @@ static void auth_old_cb(JabberStream *js
 	if (type == JABBER_IQ_ERROR) {
 		PurpleConnectionError reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 		char *msg = jabber_parse_error(js, packet, &reason);
-		purple_connection_error_reason (js->gc, reason, msg);
+		purple_connection_error_reason(js->gc, reason, msg);
 		g_free(msg);
 	} else if (type == JABBER_IQ_RESULT) {
 		query = xmlnode_get_child(packet, "query");
@@ -676,7 +676,7 @@ static void auth_old_cb(JabberStream *js
 			}
 			finish_plaintext_authentication(js);
 		} else {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE,
 				_("Server does not use any supported authentication method"));
 			return;
@@ -695,7 +695,7 @@ void jabber_auth_start_old(JabberStream 
 	 */
 	if (!jabber_stream_is_ssl(js) &&
 			purple_account_get_bool(purple_connection_get_account(js->gc), "require_tls", FALSE)) {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
 			_("You require encryption, but it is not available on this server."));
 		return;
@@ -856,9 +856,9 @@ jabber_auth_handle_challenge(JabberStrea
 		GHashTable *parts;
 
 		if(!enc_in) {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Invalid response from server."));
+				_("Invalid response from server"));
 			return;
 		}
 
@@ -879,7 +879,7 @@ jabber_auth_handle_challenge(JabberStrea
 						"<response xmlns='urn:ietf:params:xml:ns:xmpp-sasl' />",
 						-1);
 			} else {
-				purple_connection_error_reason (js->gc,
+				purple_connection_error_reason(js->gc,
 					PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 					_("Invalid challenge from server"));
 			}
@@ -905,7 +905,7 @@ jabber_auth_handle_challenge(JabberStrea
 				realm = js->user->domain;
 
 			if (nonce == NULL || realm == NULL)
-				purple_connection_error_reason (js->gc,
+				purple_connection_error_reason(js->gc,
 					PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 					_("Invalid challenge from server"));
 			else {
@@ -980,10 +980,13 @@ jabber_auth_handle_challenge(JabberStrea
 		g_free(enc_in);
 		g_free(dec_in);
 		if (js->sasl_state != SASL_CONTINUE && js->sasl_state != SASL_OK) {
-			purple_debug_error("jabber", "Error is %d : %s\n",js->sasl_state,sasl_errdetail(js->sasl));
-			purple_connection_error_reason (js->gc,
-				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("SASL error"));
+			gchar *tmp = g_strdup_printf(_("SASL error: %s"),
+					sasl_errdetail(js->sasl));
+			purple_debug_error("jabber", "Error is %d : %s\n",
+					js->sasl_state, sasl_errdetail(js->sasl));
+			purple_connection_error_reason(js->gc,
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+			g_free(tmp);
 			return;
 		} else {
 			response = xmlnode_new("response");
@@ -1025,9 +1028,9 @@ void jabber_auth_handle_success(JabberSt
 #endif
 
 	if(!ns || strcmp(ns, "urn:ietf:params:xml:ns:xmpp-sasl")) {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Invalid response from server."));
+			_("Invalid response from server"));
 		return;
 	}
 
@@ -1052,9 +1055,9 @@ void jabber_auth_handle_success(JabberSt
 
 		if (js->sasl_state != SASL_OK) {
 			/* This should never happen! */
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Invalid response from server."));
+				_("Invalid response from server"));
 		}
 	}
 	/* If we've negotiated a security layer, we need to enable it */
@@ -1098,11 +1101,11 @@ void jabber_auth_handle_failure(JabberSt
 #endif
 	msg = jabber_parse_error(js, packet, &reason);
 	if(!msg) {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Invalid response from server."));
+			_("Invalid response from server"));
 	} else {
-		purple_connection_error_reason (js->gc, reason, msg);
+		purple_connection_error_reason(js->gc, reason, msg);
 		g_free(msg);
 	}
 }
============================================================
--- libpurple/protocols/jabber/bosh.c	5b44ea1474a9c43e90167feedf9b376bbbb70e5f
+++ libpurple/protocols/jabber/bosh.c	4b25db980d197aeefe52aaf6d8275d6fcc3544bd
@@ -354,7 +354,7 @@ static gboolean jabber_bosh_connection_e
 
 	if (type != NULL && !strcmp(type, "terminate")) {
 		conn->ready = FALSE;
-		purple_connection_error_reason (conn->js->gc,
+		purple_connection_error_reason(conn->js->gc,
 			PURPLE_CONNECTION_ERROR_OTHER_ERROR,
 			_("The BOSH connection manager terminated your session."));
 		return TRUE;
@@ -783,7 +783,7 @@ connection_established_cb(gpointer data,
 
 	if (source < 0) {
 		gchar *tmp;
-		tmp = g_strdup_printf(_("Could not establish a connection with the server:\n%s"),
+		tmp = g_strdup_printf(_("Unable to establish a connection with the server: %s"),
 		        error);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
@@ -822,7 +822,7 @@ static void http_connection_connect(Purp
 	                                 connection_established_cb, conn) == NULL) {
 		purple_connection_error_reason(gc,
 		    PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		    _("Unable to create socket"));
+		    _("Unable to connect"));
 	}
 }
 
@@ -862,9 +862,12 @@ http_connection_send_cb(gpointer data, g
 		 * buffer that stores what is "being sent" until the
 		 * PurpleHTTPConnection reports it is fully sent.
 		 */
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_connection_error_reason(conn->bosh->js->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Write error"));
+				tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -905,9 +908,12 @@ http_connection_send_request(PurpleHTTPC
 		 * buffer that stores what is "being sent" until the
 		 * PurpleHTTPConnection reports it is fully sent.
 		 */
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_connection_error_reason(conn->bosh->js->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Write error"));
+				tmp);
+		g_free(tmp);
 		return;
 	} else if (ret < len) {
 		if (ret < 0)
============================================================
--- libpurple/protocols/jabber/jabber.c	6dd3827765c1db389daf15813ee5e3b82d58ccc2
+++ libpurple/protocols/jabber/jabber.c	c5c70221a012e8a06a4e5a4ff5cf88cf0da211fc
@@ -102,7 +102,7 @@ jabber_session_initialized_cb(JabberStre
 		if(js->unregistration)
 			jabber_unregister_account_cb(js);
 	} else {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 			("Error initializing session"));
 	}
@@ -135,9 +135,9 @@ static void jabber_bind_result_cb(Jabber
 			JabberBuddy *my_jb = NULL;
 			jabber_id_free(js->user);
 			if(!(js->user = jabber_id_new(full_jid))) {
-				purple_connection_error_reason (js->gc,
+				purple_connection_error_reason(js->gc,
 					PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-					_("Invalid response from server."));
+					_("Invalid response from server"));
 			}
 			if((my_jb = jabber_buddy_find(js, full_jid, TRUE)))
 				my_jb->subscription |= JABBER_SUB_BOTH;
@@ -149,7 +149,7 @@ static void jabber_bind_result_cb(Jabber
 	} else {
 		PurpleConnectionError reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 		char *msg = jabber_parse_error(js, packet, &reason);
-		purple_connection_error_reason (js->gc, reason, msg);
+		purple_connection_error_reason(js->gc, reason, msg);
 		g_free(msg);
 	}
 
@@ -196,7 +196,7 @@ void jabber_stream_features_parse(Jabber
 
 			return;
 	} else if(purple_account_get_bool(js->gc->account, "require_tls", FALSE) && !jabber_stream_is_ssl(js)) {
-		purple_connection_error_reason (js->gc,
+		purple_connection_error_reason(js->gc,
 			 PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
 			_("You require encryption, but it is not available on this server."));
 		return;
@@ -238,7 +238,7 @@ static void jabber_stream_handle_error(J
 	PurpleConnectionError reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 	char *msg = jabber_parse_error(js, packet, &reason);
 
-	purple_connection_error_reason (js->gc, reason, msg);
+	purple_connection_error_reason(js->gc, reason, msg);
 
 	g_free(msg);
 }
@@ -320,9 +320,11 @@ static void jabber_send_cb(gpointer data
 	if (ret < 0 && errno == EAGAIN)
 		return;
 	else if (ret <= 0) {
-		purple_connection_error_reason (js->gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Write error"));
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
+		purple_connection_error_reason(js->gc,
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -345,9 +347,11 @@ static gboolean do_jabber_send_raw(Jabbe
 	}
 
 	if (ret < 0 && errno != EAGAIN) {
-		purple_connection_error_reason (js->gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Write error"));
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
+		purple_connection_error_reason(js->gc,
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		success = FALSE;
 	} else if (ret < len) {
 		if (ret < 0)
@@ -473,7 +477,7 @@ static gboolean jabber_keepalive_timeout
 {
 	JabberStream *js = gc->proto_data;
 	purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-					_("Ping timeout"));
+					_("Ping timed out"));
 	js->keepalive_timeout = 0;
 	return FALSE;
 }
@@ -516,13 +520,15 @@ jabber_recv_cb_ssl(gpointer data, Purple
 	if(len < 0 && errno == EAGAIN)
 		return;
 	else {
+		gchar *tmp;
 		if (len == 0)
-			purple_debug_info("jabber", "Server closed the connection.\n");
+			tmp = g_strdup_printf(_("Server closed the connection"));
 		else
-			purple_debug_info("jabber", "Disconnected: %s\n", g_strerror(errno));
-		purple_connection_error_reason (js->gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Read Error"));
+			tmp = g_strdup_printf(_("Lost connection with server: %s"),
+					g_strerror(errno));
+		purple_connection_error_reason(js->gc,
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 	}
 }
 
@@ -561,13 +567,15 @@ jabber_recv_cb(gpointer data, gint sourc
 	} else if(len < 0 && errno == EAGAIN) {
 		return;
 	} else {
+		gchar *tmp;
 		if (len == 0)
-			purple_debug_info("jabber", "Server closed the connection.\n");
+			tmp = g_strdup_printf(_("Server closed the connection"));
 		else
-			purple_debug_info("jabber", "Disconnected: %s\n", g_strerror(errno));
-		purple_connection_error_reason (js->gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Read Error"));
+			tmp = g_strdup_printf(_("Lost connection with server: %s"),
+					g_strerror(errno));
+		purple_connection_error_reason(js->gc,
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 	}
 }
 
@@ -603,11 +611,10 @@ txt_resolved_cb(GList *responses, gpoint
 	js->srv_query_data = NULL;
 
 	if (responses == NULL) {
-		gchar *tmp;
-		tmp = g_strdup_printf(_("Could not find alternative XMPP connection methods after failing to connect directly.\n"));
-		purple_connection_error_reason (js->gc,
-				PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
-		g_free(tmp);
+		purple_connection_error_reason(js->gc,
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
+				_("Unable to find alternative XMPP connection "
+				  "methods after failing to connect directly."));
 		return;
 	}
 
@@ -709,9 +716,9 @@ static gboolean jabber_login_connect(Jab
 	if (purple_proxy_connect(js->gc, js->gc->account, host,
 			port, jabber_login_callback, js->gc) == NULL) {
 		if (fatal_failure) {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Unable to create socket"));
+				_("Unable to connect"));
 		}
 
 		return FALSE;
@@ -796,14 +803,14 @@ jabber_login(PurpleAccount *account)
 		js->idle = purple_presence_get_idle_time(presence);
 
 	if(!js->user) {
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 			_("Invalid XMPP ID"));
 		return;
 	}
 
 	if (!js->user->domain || *(js->user->domain) == '\0') {
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 			_("Invalid XMPP ID. Domain must be set."));
 		return;
@@ -835,7 +842,7 @@ jabber_login(PurpleAccount *account)
 		if (js->bosh)
 			jabber_bosh_connection_connect(js->bosh);
 		else {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 				_("Malformed BOSH URL"));
 		}
@@ -853,12 +860,12 @@ jabber_login(PurpleAccount *account)
 					purple_account_get_int(account, "port", 5223), jabber_login_callback_ssl,
 					jabber_ssl_connect_failure, js->gc);
 			if (!js->gsc) {
-				purple_connection_error_reason (js->gc,
+				purple_connection_error_reason(js->gc,
 					PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 					_("Unable to establish SSL connection"));
 			}
 		} else {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 				_("SSL support unavailable"));
 		}
@@ -1304,7 +1311,7 @@ void jabber_register_account(PurpleAccou
 	js->keepalive_timeout = 0;
 
 	if(!js->user) {
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 			_("Invalid XMPP ID"));
 		return;
@@ -1329,7 +1336,7 @@ void jabber_register_account(PurpleAccou
 		js->use_bosh = TRUE;
 		js->bosh = jabber_bosh_connection_init(js, connect_server);
 		if (!js->bosh) {
-			purple_connection_error_reason (js->gc,
+			purple_connection_error_reason(js->gc,
 				PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 				_("Malformed BOSH Connect Server"));
 			return;
@@ -1346,12 +1353,12 @@ void jabber_register_account(PurpleAccou
 					purple_account_get_int(account, "port", 5222),
 					jabber_login_callback_ssl, jabber_ssl_connect_failure, gc);
 			if (!js->gsc) {
-				purple_connection_error_reason (js->gc,
+				purple_connection_error_reason(js->gc,
 					PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 					_("Unable to establish SSL connection"));
 			}
 		} else {
-			purple_connection_error_reason (gc,
+			purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
 				_("SSL support unavailable"));
 		}
============================================================
--- libpurple/protocols/msn/msn.c	b64a12dc36b8d425c61805866b9f0a8126b02b3e
+++ libpurple/protocols/msn/msn.c	e292085d960708bbbd15589eda9218d020af6c50
@@ -1028,7 +1028,7 @@ msn_login(PurpleAccount *account)
 	if (!msn_session_connect(session, host, port, http_method))
 		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Failed to connect to server."));
+			_("Unable to connect"));
 }
 
 static void
============================================================
--- libpurple/protocols/msn/session.c	1d49938cac714059979332011b8c2e41ce76e202
+++ libpurple/protocols/msn/session.c	9c45d6773028eb5ac5adb35e17b2ed10dd9f92c6
@@ -334,15 +334,15 @@ msn_session_set_error(MsnSession *sessio
 		case MSN_ERROR_UNSUPPORTED_PROTOCOL:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 			msg = g_strdup(_("Our protocol is not supported by the "
-							 "server."));
+							 "server"));
 			break;
 		case MSN_ERROR_HTTP_MALFORMED:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
-			msg = g_strdup(_("Error parsing HTTP."));
+			msg = g_strdup(_("Error parsing HTTP"));
 			break;
 		case MSN_ERROR_SIGN_OTHER:
 			reason = PURPLE_CONNECTION_ERROR_NAME_IN_USE;
-			msg = g_strdup(_("You have signed on from another location."));
+			msg = g_strdup(_("You have signed on from another location"));
 			if (!purple_account_get_remember_password(session->account))
 				purple_account_set_password(session->account, NULL);
 			break;
@@ -355,7 +355,7 @@ msn_session_set_error(MsnSession *sessio
 		case MSN_ERROR_SERV_DOWN:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 			msg = g_strdup(_("The MSN servers are going down "
-							 "temporarily."));
+							 "temporarily"));
 			break;
 		case MSN_ERROR_AUTH:
 			reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
@@ -371,13 +371,13 @@ msn_session_set_error(MsnSession *sessio
 			break;
 		default:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
-			msg = g_strdup(_("Unknown error."));
+			msg = g_strdup(_("Unknown error"));
 			break;
 	}
 
 	msn_session_disconnect(session);
 
-	purple_connection_error_reason (gc, reason, msg);
+	purple_connection_error_reason(gc, reason, msg);
 
 	g_free(msg);
 }
============================================================
--- libpurple/protocols/msnp9/msn.c	ea2a971699e843296307573e6f7900bc4dd45396
+++ libpurple/protocols/msnp9/msn.c	7d78ee4bce45359570fbe5788f036b75fe1df9d5
@@ -789,7 +789,7 @@ msn_login(PurpleAccount *account)
 	if (!msn_session_connect(session, host, port, http_method))
 		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Failed to connect to server."));
+			_("Unable to connect"));
 }
 
 static void
============================================================
--- libpurple/protocols/msnp9/session.c	d39656c723d69763d869ad967edfba226fba63a7
+++ libpurple/protocols/msnp9/session.c	26a7b670149ee8327c71ccbe502e1c45b7fd408f
@@ -296,15 +296,15 @@ msn_session_set_error(MsnSession *sessio
 		case MSN_ERROR_UNSUPPORTED_PROTOCOL:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 			msg = g_strdup(_("Our protocol is not supported by the "
-							 "server."));
+							 "server"));
 			break;
 		case MSN_ERROR_HTTP_MALFORMED:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
-			msg = g_strdup(_("Error parsing HTTP."));
+			msg = g_strdup(_("Error parsing HTTP"));
 			break;
 		case MSN_ERROR_SIGN_OTHER:
 			reason = PURPLE_CONNECTION_ERROR_NAME_IN_USE;
-			msg = g_strdup(_("You have signed on from another location."));
+			msg = g_strdup(_("You have signed on from another location"));
 			if (!purple_account_get_remember_password(session->account))
 				purple_account_set_password(session->account, NULL);
 			break;
@@ -317,7 +317,7 @@ msn_session_set_error(MsnSession *sessio
 		case MSN_ERROR_SERV_DOWN:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 			msg = g_strdup(_("The MSN servers are going down "
-							 "temporarily."));
+							 "temporarily"));
 			break;
 		case MSN_ERROR_AUTH:
 			reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
@@ -333,13 +333,13 @@ msn_session_set_error(MsnSession *sessio
 			break;
 		default:
 			reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
-			msg = g_strdup(_("Unknown error."));
+			msg = g_strdup(_("Unknown error"));
 			break;
 	}
 
 	msn_session_disconnect(session);
 
-	purple_connection_error_reason (gc, reason, msg);
+	purple_connection_error_reason(gc, reason, msg);
 
 	g_free(msg);
 }
============================================================
--- libpurple/protocols/myspace/myspace.c	fc8b3c2a1eea1e41254621fa5e1912c8d355023c
+++ libpurple/protocols/myspace/myspace.c	8f54dae1ecff9956971bfe905d19a55650a5e444
@@ -1870,7 +1870,7 @@ msim_error(MsimSession *session, MsimMes
 					purple_account_set_password(session->account, NULL);
 				break;
 		}
-		purple_connection_error_reason (session->gc, reason, full_errmsg);
+		purple_connection_error_reason(session->gc, reason, full_errmsg);
 	} else {
 		purple_notify_error(session->account, _("MySpaceIM Error"), full_errmsg, NULL);
 	}
@@ -2069,21 +2069,23 @@ msim_input_cb(gpointer gc_uncasted, gint
 		 session->rxbuf + session->rxoff,
 		 session->rxsize - session->rxoff - 1, 0);
 
-	if (n < 0 && errno == EAGAIN) {
+	if (n < 0) {
+		gchar *tmp;
+
+		if (errno == EAGAIN)
+			/* No worries */
+			return;
+
+		tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
+		purple_connection_error_reason(gc,
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
-	} else if (n < 0) {
-		purple_debug_error("msim", "msim_input_cb: read error, ret=%d, "
-			"error=%s, source=%d, fd=%d (%X))\n",
-			n, g_strerror(errno), source, session->fd, session->fd);
-		purple_connection_error_reason (gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Read error"));
-		return;
 	} else if (n == 0) {
-		purple_debug_info("msim", "msim_input_cb: server disconnected\n");
-		purple_connection_error_reason (gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Server has disconnected"));
+		purple_connection_error_reason(gc,
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
+				_("Server closed the connection"));
 		return;
 	}
 
@@ -2126,7 +2128,7 @@ msim_input_cb(gpointer gc_uncasted, gint
 			purple_debug_info("msim", "msim_input_cb: couldn't parse rxbuf\n");
 			purple_connection_error_reason (gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Unparseable message"));
+				_("Unable to parse message"));
 			break;
 		} else {
 			/* Process message and then free it (processing function should
@@ -2167,11 +2169,11 @@ msim_connect_cb(gpointer data, gint sour
 	session = (MsimSession *)gc->proto_data;
 
 	if (source < 0) {
+		gchar *tmp = g_strdup_printf(_("Unable to connect: %s"),
+				error_message);
 		purple_connection_error_reason (gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			g_strdup_printf(_("Couldn't connect to host: %s (%d)"),
-					error_message ? error_message : "no message given",
-					source));
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+			g_free(tmp);
 		return;
 	}
 
@@ -2228,7 +2230,7 @@ msim_login(PurpleAccount *acct)
 		 * working port and try that first next time. */
 		purple_connection_error_reason (gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Couldn't create socket"));
+			_("Unable to connect"));
 		return;
 	}
 }
============================================================
--- libpurple/protocols/myspace/user.c	2aea7bfa9b950a358de386796ef70128765975af
+++ libpurple/protocols/myspace/user.c	b902e0a2214de7f9c2312e75cda3ad6c7a1fc49a
@@ -637,8 +637,7 @@ static void msim_username_is_set_cb(Msim
 	uid = msim_msg_get_integer(userinfo, "uid");
 	lid = msim_msg_get_integer(userinfo, "lid");
 	body = msim_msg_get_dictionary(userinfo, "body");
-	/* XXX: Mark for translation */
-	errmsg = ("An error occurred while trying to set the username.\n"
+	errmsg = _("An error occurred while trying to set the username.  "
 			"Please try again, or visit http://editprofile.myspace.com/index.cfm?"
 			"fuseaction=profile.username to set your username.");
 
@@ -797,9 +796,9 @@ static void msim_username_is_available_c
 	if (!body) {
 		purple_debug_info("msim_username_is_available_cb", "No body for %s?!\n", username);
 		purple_connection_error_reason(session->gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-				"An error occurred while trying to set the username.\n"
+				_("An error occurred while trying to set the username.  "
 				"Please try again, or visit http://editprofile.myspace.com/index.cfm?"
-				"fuseaction=profile.username to set your username.");
+				"fuseaction=profile.username to set your username."));
 		return;
 	}
 
============================================================
--- libpurple/protocols/novell/novell.c	33f13bbfe828a17435d90b943a07875d020c5b22
+++ libpurple/protocols/novell/novell.c	f6c315b410d4623cd310b5921ae957fbc00cc5f0
@@ -121,7 +121,7 @@ _login_resp_cb(NMUser * user, NMERR_T re
 
 	} else {
 		PurpleConnectionError reason;
-		char *err = g_strdup_printf(_("Login failed (%s)."),
+		char *err = g_strdup_printf(_("Unable to login: %s"),
 					    nm_error_to_string (ret_code));
 
 		switch (ret_code) {
@@ -140,7 +140,7 @@ _login_resp_cb(NMUser * user, NMERR_T re
 				reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 		}
 
-		purple_connection_error_reason (gc, reason, err);
+		purple_connection_error_reason(gc, reason, err);
 		g_free(err);
 	}
 }
@@ -1126,7 +1126,7 @@ _check_for_disconnect(NMUser * user, NME
 
 	if (_is_disconnect_error(err)) {
 
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 			_("Error communicating with server. Closing connection."));
 		return TRUE;
@@ -1701,7 +1701,7 @@ novell_ssl_recv_cb(gpointer data, Purple
 
 		if (_is_disconnect_error(rc)) {
 
-			purple_connection_error_reason (gc,
+			purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 				_("Error communicating with server. Closing connection."));
 		} else {
@@ -1742,9 +1742,9 @@ novell_ssl_connected_cb(gpointer data, P
 		conn->connected = TRUE;
 		purple_ssl_input_add(gsc, novell_ssl_recv_cb, gc);
 	} else {
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Unable to connect to server."));
+			_("Unable to connect"));
 	}
 
 	purple_connection_update_progress(gc, _("Waiting for response..."),
@@ -2027,10 +2027,9 @@ _evt_user_disconnect(NMUser * user, NMEv
 	{
 		if (!purple_account_get_remember_password(account))
 			purple_account_set_password(account, NULL);
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NAME_IN_USE,
-			_("You have been logged out because you"
-			  " logged in at another workstation."));
+			_("You have signed on from another location"));
 	}
 }
 
@@ -2184,7 +2183,7 @@ novell_login(PurpleAccount * account)
 		 */
 
 		/* ...but for now just error out with a nice message. */
-		purple_connection_error_reason (gc,
+		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_INVALID_SETTINGS,
 			_("Unable to connect to server. Please enter the "
 			  "address of the server to which you wish to connect."));
@@ -2213,9 +2212,9 @@ novell_login(PurpleAccount * account)
 													  user->conn->addr, user->conn->port,
 													  novell_ssl_connected_cb, novell_ssl_connect_error, gc);
 		if (user->conn->ssl_conn->data == NULL) {
-			purple_connection_error_reason (gc,
+			purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT,
-				_("Error. SSL support is not installed."));
+				_("SSL support unavailable"));
 		}
 	}
 }
============================================================
--- libpurple/protocols/oscar/clientlogin.c	87bcb6becc342bda8c438824aa510d62f1da1815
+++ libpurple/protocols/oscar/clientlogin.c	c008e2fc3bd58b7491e126a1c4b04157dc817d0e
@@ -377,11 +377,11 @@ static gboolean parse_client_login_respo
 		if (status_code == 330 && status_detail_code == 3011) {
 			purple_connection_error_reason(gc,
 					PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED,
-					_("Incorrect password."));
+					_("Incorrect password"));
 		} else if (status_code == 401 && status_detail_code == 3019) {
 			purple_connection_error_reason(gc,
 					PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-					_("AOL does not allow your screen name to authenticate via this site."));
+					_("AOL does not allow your screen name to authenticate here"));
 		} else
 			purple_connection_error_reason(gc,
 					PURPLE_CONNECTION_ERROR_OTHER_ERROR,
============================================================
--- libpurple/protocols/oscar/flap_connection.c	e76486f40fd307c094c39f6a6cc824b1df476d54
+++ libpurple/protocols/oscar/flap_connection.c	318e6616a1f7ef23b5764674a6dd94954035e8ca
@@ -480,7 +480,7 @@ flap_connection_destroy_cb(gpointer data
 		else if (conn->disconnect_reason == OSCAR_DISCONNECT_INVALID_DATA)
 			tmp = g_strdup(_("Received invalid data on connection with server"));
 		else if (conn->disconnect_reason == OSCAR_DISCONNECT_COULD_NOT_CONNECT)
-			tmp = g_strdup_printf(_("Could not establish a connection with the server: %s"),
+			tmp = g_strdup_printf(_("Unable to connect: %s"),
 					conn->error_message);
 		else
 			/*
============================================================
--- libpurple/protocols/oscar/odc.c	97737a449c40d001234b5419bb0f470dee9c4c6a
+++ libpurple/protocols/oscar/odc.c	246f66c33d1a709c1dd5efd1c16b8d80aaa858ba
@@ -48,7 +48,7 @@ peer_odc_close(PeerConnection *conn)
 	else if (conn->disconnect_reason == OSCAR_DISCONNECT_INVALID_DATA)
 		tmp = g_strdup(_("Received invalid data on connection with remote user."));
 	else if (conn->disconnect_reason == OSCAR_DISCONNECT_COULD_NOT_CONNECT)
-		tmp = g_strdup(_("Could not establish a connection with the remote user."));
+		tmp = g_strdup(_("Unable to establish a connection with the remote user."));
 	else
 		/*
 		 * We shouldn't print a message for some disconnect_reasons.
============================================================
--- libpurple/protocols/oscar/oscar.c	151efda98cd8a90efb6055e76cfff03ea0de4c8b
+++ libpurple/protocols/oscar/oscar.c	cff2caf98136c93762574d29bd1276debd80113b
@@ -1111,7 +1111,7 @@ connection_common_error_cb(FlapConnectio
 	{
 		/* This only happens when connecting with the old-style BUCP login */
 		gchar *msg;
-		msg = g_strdup_printf(_("Could not connect to authentication server:\n%s"),
+		msg = g_strdup_printf(_("Unable to connect to authentication server: %s"),
 				error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, msg);
 		g_free(msg);
@@ -1119,7 +1119,7 @@ connection_common_error_cb(FlapConnectio
 	else if (conn->type == SNAC_FAMILY_LOCATE)
 	{
 		gchar *msg;
-		msg = g_strdup_printf(_("Could not connect to BOS server:\n%s"),
+		msg = g_strdup_printf(_("Unable to connect to BOS server: %s"),
 				error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, msg);
 		g_free(msg);
@@ -1521,7 +1521,7 @@ oscar_login(PurpleAccount *account)
 
 	if (!oscar_util_valid_name(purple_account_get_username(account))) {
 		gchar *buf;
-		buf = g_strdup_printf(_("Unable to login: Could not sign on as %s because the username is invalid.  Usernames must be a valid email address, or start with a letter and contain only letters, numbers and spaces, or contain only numbers."), purple_account_get_username(account));
+		buf = g_strdup_printf(_("Unable to sign on as %s because the username is invalid.  Usernames must be a valid email address, or start with a letter and contain only letters, numbers and spaces, or contain only numbers."), purple_account_get_username(account));
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_INVALID_SETTINGS, buf);
 		g_free(buf);
 		return;
@@ -1605,7 +1605,7 @@ oscar_login(PurpleAccount *account)
 
 		if (newconn->gsc == NULL && newconn->connect_data == NULL) {
 			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-					_("Couldn't connect to host"));
+					_("Unable to connect"));
 			return;
 		}
 	}
@@ -1841,7 +1841,7 @@ int oscar_connect_to_bos(PurpleConnectio
 			connection_established_cb, conn);
 	if (conn->connect_data == NULL)
 	{
-		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Could Not Connect"));
+		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Unable to connect"));
 		return 0;
 	}
 
@@ -1887,11 +1887,11 @@ purple_parse_auth_resp(OscarData *od, Fl
 			/* Incorrect password */
 			if (!purple_account_get_remember_password(account))
 				purple_account_set_password(account, NULL);
-			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, _("Incorrect password."));
+			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, _("Incorrect password"));
 			break;
 		case 0x11:
 			/* Suspended account */
-			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, _("Your account is currently suspended."));
+			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, _("Your account is currently suspended"));
 			break;
 		case 0x02:
 		case 0x14:
@@ -1963,7 +1963,7 @@ purple_parse_auth_resp(OscarData *od, Fl
 	g_free(host);
 	if (newconn->connect_data == NULL)
 	{
-		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Could Not Connect"));
+		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Unable to connect"));
 		return 0;
 	}
 
@@ -1996,7 +1996,7 @@ purple_parse_auth_securid_request_no_cb(
 	/* Disconnect */
 	purple_connection_error_reason(gc,
 		PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED,
-		_("The SecurID key entered is invalid."));
+		_("The SecurID key entered is invalid"));
 }
 
 /**
@@ -4976,7 +4976,7 @@ oscar_add_buddy(PurpleConnection *gc, Pu
 
 	if (!oscar_util_valid_name(bname)) {
 		gchar *buf;
-		buf = g_strdup_printf(_("Could not add the buddy %s because the username is invalid.  Usernames must be a valid email address, or start with a letter and contain only letters, numbers and spaces, or contain only numbers."), bname);
+		buf = g_strdup_printf(_("Unable to add the buddy %s because the username is invalid.  Usernames must be a valid email address, or start with a letter and contain only letters, numbers and spaces, or contain only numbers."), bname);
 		if (!purple_conv_present_error(bname, account, buf))
 			purple_notify_error(gc, NULL, _("Unable to Add"), buf);
 		g_free(buf);
@@ -5461,7 +5461,7 @@ static int purple_ssi_parseack(OscarData
 
 			case 0x000c: { /* you are over the limit, the cheat is to the limit, come on fhqwhgads */
 				gchar *buf;
-				buf = g_strdup_printf(_("Could not add the buddy %s because you have too many buddies in your buddy list.  Please remove one and try again."), (retval->name ? retval->name : _("(no name)")));
+				buf = g_strdup_printf(_("Unable to add the buddy %s because you have too many buddies in your buddy list.  Please remove one and try again."), (retval->name ? retval->name : _("(no name)")));
 				if ((retval->name != NULL) && !purple_conv_present_error(retval->name, purple_connection_get_account(gc), buf))
 					purple_notify_error(gc, NULL, _("Unable to Add"), buf);
 				g_free(buf);
@@ -5475,7 +5475,7 @@ static int purple_ssi_parseack(OscarData
 			default: { /* La la la */
 				gchar *buf;
 				purple_debug_error("oscar", "ssi: Action 0x%04hx was unsuccessful with error 0x%04hx\n", retval->action, retval->ack);
-				buf = g_strdup_printf(_("Could not add the buddy %s for an unknown reason."),
+				buf = g_strdup_printf(_("Unable to add the buddy %s for an unknown reason."),
 						(retval->name ? retval->name : _("(no name)")));
 				if ((retval->name != NULL) && !purple_conv_present_error(retval->name, purple_connection_get_account(gc), buf))
 					purple_notify_error(gc, NULL, _("Unable to Add"), buf);
============================================================
--- libpurple/protocols/qq/qq_base.c	c8da79024ef3f493ddd8eef7006c3f6db6433f5f
+++ libpurple/protocols/qq/qq_base.c	9c785f33f0dac7ee34edb881e722a26dc9cce481
@@ -72,7 +72,7 @@ static gint8 process_login_ok(PurpleConn
 		qq_show_packet("Login reply OK, but length < 139", data, len);
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
-				_("Cannot decrypt server reply"));
+				_("Unable to decrypt server reply"));
 		return QQ_LOGIN_REPLY_ERR;
 	}
 
@@ -160,7 +160,7 @@ static gint8 process_login_redirect(Purp
 	if (len < 11) {
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
-				_("Cannot decrypt server reply"));
+				_("Unable to decrypt server reply"));
 		return QQ_LOGIN_REPLY_ERR;
 	}
 
@@ -412,7 +412,7 @@ guint8 qq_process_login( PurpleConnectio
 			if (!purple_account_get_remember_password(gc->account)) {
 				purple_account_set_password(gc->account, NULL);
 			}
-			error = g_strdup( _("Incorrect password."));
+			error = g_strdup( _("Incorrect password"));
 			reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
 			break;
 		case 0x06:		/* need activation */
@@ -655,7 +655,7 @@ guint16 qq_process_get_server(PurpleConn
 	if (data_len < 15) {
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
-				_("Could not decrypt server reply"));
+				_("Unable to decrypt server reply"));
 		return QQ_LOGIN_REPLY_ERR;
 	}
 
@@ -1097,7 +1097,7 @@ guint8 qq_process_check_pwd( PurpleConne
 			if (!purple_account_get_remember_password(gc->account)) {
 				purple_account_set_password(gc->account, NULL);
 			}
-			error = g_strdup(_("Incorrect password."));
+			error = g_strdup(_("Incorrect password"));
 			reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
 			break;
 		case 0x33:		/* need activation */
@@ -1106,7 +1106,7 @@ guint8 qq_process_check_pwd( PurpleConne
 			reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
 			break;
 		case 0xBF:		/* uid is not exist */
-			error = g_strdup(_("Invalid username."));
+			error = g_strdup(_("Username does not exist"));
 			reason = PURPLE_CONNECTION_ERROR_INVALID_USERNAME;
 			break;
 		default:
============================================================
--- libpurple/protocols/qq/qq_network.c	2157ebcbcf5a955908441364e7edcaf4561d2d6d
+++ libpurple/protocols/qq/qq_network.c	105c215f6e274425d41428930520b4da1c08af9c
@@ -208,7 +208,7 @@ gboolean qq_connect_later(gpointer data)
 		if ( set_new_server(qd) != TRUE) {
 			purple_connection_error_reason(gc,
 					PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-					_("Unable to connect."));
+					_("Unable to connect"));
 			return FALSE;
 		}
 		qd->connect_retry = QQ_CONNECT_MAX;
@@ -233,7 +233,7 @@ gboolean qq_connect_later(gpointer data)
 	if ( !connect_to_server(gc, tmp_server, port) ) {
 			purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Unable to connect."));
+				_("Unable to connect"));
 	}
 
 	g_free(tmp_server);
@@ -389,7 +389,7 @@ static void tcp_pending(gpointer data, g
 			/* No worries */
 			return;
 
-		error_msg = g_strdup_printf(_("Lost connection with server:\n%s"), g_strerror(errno));
+		error_msg = g_strdup_printf(_("Lost connection with server: %s"), g_strerror(errno));
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 				error_msg);
@@ -397,7 +397,7 @@ static void tcp_pending(gpointer data, g
 		return;
 	} else if (buf_len == 0) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Server closed the connection."));
+				_("Server closed the connection"));
 		return;
 	}
 
@@ -585,9 +585,11 @@ static void tcp_can_write(gpointer data,
 		return;
 	else if (ret < 0) {
 		/* TODO: what to do here - do we really have to disconnect? */
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_connection_error_reason(gc,
-				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		        _("Write Error"));
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -629,11 +631,13 @@ static gint tcp_send_out(PurpleConnectio
 		ret = 0;
 	} else if (ret <= 0) {
 		/* TODO: what to do here - do we really have to disconnect? */
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_debug_error("TCP_SEND_OUT",
 			"Send to socket %d failed: %d, %s\n", qd->fd, errno, g_strerror(errno));
 		purple_connection_error_reason(gc,
-				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				g_strerror(errno));
+				PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return ret;
 	}
 
@@ -663,7 +667,7 @@ static gboolean network_timeout(gpointer
 	if (is_lost_conn) {
 		purple_connection_error_reason(gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Connection lost"));
+			_("Lost connection with server"));
 		return TRUE;
 	}
 
@@ -864,7 +868,7 @@ static void udp_host_resolved(GSList *ho
 	if (!hosts || !hosts->data) {
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Couldn't resolve host"));
+				_("Unable to resolve hostname"));
 		return;
 	}
 
@@ -941,7 +945,7 @@ gboolean connect_to_server(PurpleConnect
 	account = purple_connection_get_account(gc);
 	qd = (qq_data *) gc->proto_data;
 
-	if (server == NULL || strlen(server) == 0 || port == 0) {
+	if (server == NULL || server[0] == '\0' || port == 0) {
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
 				_("Invalid server or port"));
============================================================
--- libpurple/protocols/qq/qq_process.c	b73d817e0676d6fcaa4abac490f6b58a6663fdf5
+++ libpurple/protocols/qq/qq_process.c	79a3fcb52c95770011eac95a977b6925aded5076
@@ -951,7 +951,7 @@ guint8 qq_proc_login_cmds(PurpleConnecti
 		qq_show_packet("Can not decrypted", rcved, rcved_len);
 		purple_connection_error_reason(gc,
 				PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR,
-				_("Could not decrypt login reply"));
+				_("Unable to decrypt login reply"));
 		return QQ_LOGIN_REPLY_ERR;
 	}
 
============================================================
--- libpurple/protocols/sametime/sametime.c	5563fc6d7ae449bcd5e5654eae73bf4f209e7d1c
+++ libpurple/protocols/sametime/sametime.c	4951653f013dc91cbf7c5c757e2aa443c52a8612
@@ -411,11 +411,14 @@ static int mw_session_io_write(struct mw
     pd->outpa = purple_input_add(pd->socket, PURPLE_INPUT_WRITE, write_cb, pd);
 
   } else if(len > 0) {
+	gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+			g_strerror(errno));
     DEBUG_ERROR("write returned %" G_GSSIZE_FORMAT ", %" G_GSIZE_FORMAT
 			" bytes left unwritten\n", ret, len);
     purple_connection_error_reason(pd->gc,
                                    PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-                                   _("Connection closed (writing)"));
+                                   tmp);
+	g_free(tmp);
 
 #if 0
     close(pd->socket);
@@ -1755,11 +1758,10 @@ static void read_cb(gpointer data, gint 
   }
 
   if(! ret) {
-    const char *msg = _("Connection reset");
     DEBUG_INFO("connection reset\n");
     purple_connection_error_reason(pd->gc,
                                    PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-                                   msg);
+                                   _("Server closed the connection"));
 
   } else if(ret < 0) {
     const gchar *err_str = g_strerror(err);
@@ -1767,7 +1769,7 @@ static void read_cb(gpointer data, gint 
 
     DEBUG_INFO("error in read callback: %s\n", err_str);
 
-    msg = g_strdup_printf(_("Error reading from socket: %s"), err_str);
+    msg = g_strdup_printf(_("Lost connection with server: %s"), err_str);
     purple_connection_error_reason(pd->gc,
                                    PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
                                    msg);
@@ -1792,10 +1794,12 @@ static void connect_cb(gpointer data, gi
 
     } else {
       /* this is a regular connect, error out */
-      const char *msg = _("Unable to connect to host");
+      gchar *tmp = g_strdup_printf(_("Unable to connect: %s"),
+          error_message);
       purple_connection_error_reason(pd->gc,
                                      PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-                                     msg);
+                                     tmp);
+      g_free(tmp);
     }
 
     return;
@@ -3800,7 +3804,7 @@ static void mw_prpl_login(PurpleAccount 
 
   if (purple_proxy_connect(gc, account, host, port, connect_cb, pd) == NULL) {
     purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-                                   _("Unable to connect to host"));
+                                   _("Unable to connect"));
   }
 }
 
============================================================
--- libpurple/protocols/silc/ops.c	89049a403cabd0a1017f8f3c9e1d923006743e76
+++ libpurple/protocols/silc/ops.c	917d7cfe9bd5fff8c6f9b0d104e54eacbb09f428
@@ -71,7 +71,7 @@ void silc_say(SilcClient client, SilcCli
 		gc = client->application;
 
 	if (gc != NULL)
-		purple_connection_error_reason (gc, reason, tmp);
+		purple_connection_error_reason(gc, reason, tmp);
 	else
 		purple_notify_error(NULL, _("Error"), _("Error occurred"), tmp);
 }
============================================================
--- libpurple/protocols/silc/silc.c	0e9c806ba280d60ebfda94d254f83aac9fe89767
+++ libpurple/protocols/silc/silc.c	03bdf97b3b824b8103dd2f42e5565adf72913566
@@ -325,7 +325,7 @@ silcpurple_connect_cb(SilcClient client,
 
 	case SILC_CLIENT_CONN_ERROR:
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		                             _("Error during connecting to SILC Server"));
+		                             _("Error connecting to SILC Server"));
 		g_unlink(silcpurple_session_file(purple_account_get_username(sg->account)));
 		break;
 
@@ -348,7 +348,7 @@ silcpurple_connect_cb(SilcClient client,
 
 	case SILC_CLIENT_CONN_ERROR_TIMEOUT:
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		                             _("Connection Timeout"));
+		                             _("Connection timed out"));
 		break;
 	}
 
@@ -447,7 +447,7 @@ static void silcpurple_continue_running(
 				 silcpurple_login_connected, gc) == NULL)
 	{
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		                             _("Unable to create connection"));
+		                             _("Unable to connect"));
 		gc->proto_data = NULL;
 		silc_free(sg);
 		return;
@@ -490,7 +490,7 @@ static void silcpurple_got_password_cb(P
 				password,
 				&sg->public_key, &sg->private_key)) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-		                             _("Could not load SILC key pair"));
+		                             _("Unable to load SILC key pair"));
 		gc->proto_data = NULL;
 		silc_free(sg);
 		return;
@@ -506,7 +506,7 @@ static void silcpurple_no_password_cb(Pu
 		return;
 	sg = gc->proto_data;
 	purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-			_("Could not load SILC key pair"));
+			_("Unable to load SILC key pair"));
 	gc->proto_data = NULL;
 	silc_free(sg);
 }
@@ -535,7 +535,7 @@ static void silcpurple_running(SilcClien
 			return;
 		}
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-		                             _("Could not load SILC key pair"));
+		                             _("Unable to not load SILC key pair"));
 		gc->proto_data = NULL;
 		silc_free(sg);
 		return;
@@ -617,7 +617,7 @@ silcpurple_login(PurpleAccount *account)
 	if (!silc_client_init(client, username, hostname, realname,
 			      silcpurple_running, sg)) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-		                             _("Cannot initialize SILC protocol"));
+		                             _("Unable to initialize SILC protocol"));
 		gc->proto_data = NULL;
 		silc_free(sg);
 		silc_free(hostname);
============================================================
--- libpurple/protocols/silc/util.c	915112e7c3cca15157692bee02f5156250a61123
+++ libpurple/protocols/silc/util.c	20b5a87318a6f38c763cb22f4415c8e26dfa77b8
@@ -213,7 +213,7 @@ gboolean silcpurple_check_silc_dir(Purpl
 						  ? "" : gc->password,
 						  NULL, NULL, FALSE)) {
 				purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-				                             _("Cannot create SILC key pair\n"));
+				                             _("Unable to create SILC key pair"));
 				return FALSE;
 			}
 
@@ -256,7 +256,7 @@ gboolean silcpurple_check_silc_dir(Purpl
 						  ? "" : gc->password,
 						  NULL, NULL, FALSE)) {
 				purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-				                             _("Cannot create SILC key pair\n"));
+				                             _("Unable to create SILC key pair"));
 				return FALSE;
 			}
 
============================================================
--- libpurple/protocols/silc10/ops.c	432877fccc4fe48eef9e929a835e298f1303f3b6
+++ libpurple/protocols/silc10/ops.c	538a6e95b16f19b0c893a566aed50e80fc69c272
@@ -1722,7 +1722,7 @@ silc_connected(SilcClient client, SilcCl
 
 	case SILC_CLIENT_CONN_ERROR_TIMEOUT:
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Connection Timeout"));
+			_("Connection timed out"));
 		break;
 	}
 
============================================================
--- libpurple/protocols/silc10/silc.c	bf0677b475a1461d75c61731270a279dd638d483
+++ libpurple/protocols/silc10/silc.c	558f05f118164a877683de3a250ea7da9a97d02f
@@ -183,7 +183,7 @@ silcpurple_login_connected(gpointer data
 			  purple_account_get_int(account, "port", 706), sg);
 	if (!conn) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Cannot initialize SILC Client connection"));
+			_("Unable to initialize SILC Client connection"));
 		gc->proto_data = NULL;
 		return;
 	}
@@ -315,7 +315,7 @@ silcpurple_login(PurpleAccount *account)
 	/* Init SILC client */
 	if (!silc_client_init(client)) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-		                             _("Cannot initialize SILC protocol"));
+		                             _("Unable to initialize SILC protocol"));
 		return;
 	}
 
@@ -336,9 +336,9 @@ silcpurple_login(PurpleAccount *account)
 							(char *)purple_account_get_string(account, "private-key", prd),
 				(gc->password == NULL) ? "" : gc->password, &client->pkcs,
 				&client->public_key, &client->private_key)) {
-		g_snprintf(pkd, sizeof(pkd), _("Could not load SILC key pair: %s"), g_strerror(errno));
+		g_snprintf(pkd, sizeof(pkd), _("Unable to load SILC key pair: %s"), g_strerror(errno));
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-		                             _("Could not load SILC key pair"));
+		                             pkd);
 		return;
 	}
 
============================================================
--- libpurple/protocols/simple/simple.c	6c3aaed7b7081a1bb904ae604a12f209ca1b47dd
+++ libpurple/protocols/simple/simple.c	290ff895d3983f3b558d0732889da3462678bfcf
@@ -428,11 +428,13 @@ static void simple_canwrite_cb(gpointer 
 
 	if(written < 0 && errno == EAGAIN)
 		written = 0;
-	else if(written <= 0) {
+	else if (written <= 0) {
 		/*TODO: do we really want to disconnect on a failure to write?*/
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_connection_error_reason(gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not write"));
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -441,15 +443,17 @@ static void simple_input_cb(gpointer dat
 
 static void simple_input_cb(gpointer data, gint source, PurpleInputCondition cond);
 
-static void send_later_cb(gpointer data, gint source, const gchar *error) {
+static void send_later_cb(gpointer data, gint source, const gchar *error_message) {
 	PurpleConnection *gc = data;
 	struct simple_account_data *sip;
 	struct sip_connection *conn;
 
 	if(source < 0) {
+		gchar *tmp = g_strdup_printf(_("Unable to connect: %s"),
+				error_message);
 		purple_connection_error_reason(gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not connect"));
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -475,7 +479,7 @@ static void sendlater(PurpleConnection *
 	if(!sip->connecting) {
 		purple_debug_info("simple", "connecting to %s port %d\n", sip->realhostname ? sip->realhostname : "{NULL}", sip->realport);
 		if (purple_proxy_connect(gc, sip->account, sip->realhostname, sip->realport, send_later_cb, gc) == NULL) {
-			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Couldn't create socket"));
+			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, _("Unable to connect"));
 		}
 		sip->connecting = TRUE;
 	}
@@ -1120,7 +1124,7 @@ gboolean process_register_response(struc
 						purple_account_set_password(sip->gc->account, NULL);
 					purple_connection_error_reason(sip->gc,
 						PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED,
-						_("Incorrect password."));
+						_("Incorrect password"));
 					return TRUE;
 				}
 				tmp = sipmsg_find_header(msg, "WWW-Authenticate");
@@ -1135,7 +1139,7 @@ gboolean process_register_response(struc
 				if (sip->registrar.retries > SIMPLE_REGISTER_RETRY_MAX) {
 					purple_connection_error_reason(sip->gc,
 						PURPLE_CONNECTION_ERROR_OTHER_ERROR,
-						_("Unknown server response."));
+						_("Unknown server response"));
 					return TRUE;
 				}
 				sip->registerstatus = SIMPLE_REGISTER_RETRY;
@@ -1729,9 +1733,11 @@ static void login_cb(gpointer data, gint
 	struct sip_connection *conn;
 
 	if(source < 0) {
+		gchar *tmp = g_strdup_printf(_("Unable to connect: %s"),
+				error_message);
 		purple_connection_error_reason(gc,
-			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not connect"));
+			PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 		return;
 	}
 
@@ -1767,7 +1773,7 @@ static void simple_udp_host_resolved_lis
 	if(listenfd == -1) {
 		purple_connection_error_reason(sip->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not create listen socket"));
+			_("Unable to create listen socket"));
 		return;
 	}
 
@@ -1792,7 +1798,7 @@ static void simple_udp_host_resolved(GSL
 	if (!hosts || !hosts->data) {
 		purple_connection_error_reason(sip->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Couldn't resolve host"));
+			_("Unable to resolve hostname"));
 		return;
 	}
 
@@ -1813,7 +1819,7 @@ static void simple_udp_host_resolved(GSL
 	if (sip->listen_data == NULL) {
 		purple_connection_error_reason(sip->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not create listen socket"));
+			_("Unable to create listen socket"));
 		return;
 	}
 }
@@ -1828,7 +1834,7 @@ simple_tcp_connect_listen_cb(int listenf
 	if(sip->listenfd == -1) {
 		purple_connection_error_reason(sip->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Could not create listen socket"));
+			_("Unable to create listen socket"));
 		return;
 	}
 
@@ -1843,7 +1849,7 @@ simple_tcp_connect_listen_cb(int listenf
 			sip->realport, login_cb, sip->gc) == NULL) {
 		purple_connection_error_reason(sip->gc,
 			PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Couldn't create socket"));
+			_("Unable to connect"));
 	}
 }
 
@@ -1883,7 +1889,7 @@ static void srvresolved(PurpleSrvRespons
 		if (sip->listen_data == NULL) {
 			purple_connection_error_reason(sip->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Could not create listen socket"));
+				_("Unable to create listen socket"));
 			return;
 		}
 	} else { /* UDP */
@@ -1893,7 +1899,7 @@ static void srvresolved(PurpleSrvRespons
 		if (sip->query_data == NULL) {
 			purple_connection_error_reason(sip->gc,
 				PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Could not resolve hostname"));
+				_("Unable to resolve hostname"));
 		}
 	}
 }
============================================================
--- libpurple/protocols/yahoo/yahoo.c	6c0b138eb3730bdeb7c5da4b96d65a8ba9abfa07
+++ libpurple/protocols/yahoo/yahoo.c	eaff22e77822ac6fe2ae707fc341c38138814505
@@ -156,7 +156,7 @@ static void yahoo_process_status(PurpleC
 		if (!purple_account_get_remember_password(account))
 			purple_account_set_password(account, NULL);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NAME_IN_USE,
-			_("You have signed on from another location."));
+			_("You have signed on from another location"));
 		return;
 	}
 
@@ -1793,12 +1793,12 @@ static void yahoo_auth16_stage1_cb(Purpl
 					/* Set password to NULL. Avoids account locking. Brings dialog to enter password if clicked on Re-enable account */
 					if (!purple_account_get_remember_password(purple_connection_get_account(gc)))
 						purple_account_set_password(purple_connection_get_account(gc), NULL);
-					error_reason = g_strdup(_("Incorrect Password"));
+					error_reason = g_strdup(_("Incorrect password"));
 					error = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
 					break;
 				case 1213:
 					/* security lock from too many failed login attempts */
-					error_reason = g_strdup(_("Account locked: Too many failed login attempts.\nLogging into the Yahoo! website may fix this."));
+					error_reason = g_strdup(_("Account locked: Too many failed login attempts.  Logging into the Yahoo! website may fix this."));
 					error = PURPLE_CONNECTION_ERROR_OTHER_ERROR;
 					break;
 				case 1235:
@@ -1809,7 +1809,7 @@ static void yahoo_auth16_stage1_cb(Purpl
 				case 1214:
 				case 1236:
 					/* indicates a lock of some description */
-					error_reason = g_strdup(_("Account locked: Unknown reason.\nLogging into the Yahoo! website may fix this."));
+					error_reason = g_strdup(_("Account locked: Unknown reason.  Logging into the Yahoo! website may fix this."));
 					error = PURPLE_CONNECTION_ERROR_OTHER_ERROR;
 					break;
 				case 100:
@@ -2050,11 +2050,11 @@ static void yahoo_process_authresp(Purpl
 
 	switch (err) {
 	case 0:
-		msg = g_strdup(_("Unknown error."));
+		msg = g_strdup(_("Unknown error"));
 		reason = PURPLE_CONNECTION_ERROR_NETWORK_ERROR;
 		break;
 	case 3:
-		msg = g_strdup(_("Invalid username."));
+		msg = g_strdup(_("Username does not exist"));
 		reason = PURPLE_CONNECTION_ERROR_INVALID_USERNAME;
 		break;
 	case 13:
@@ -2076,7 +2076,7 @@ static void yahoo_process_authresp(Purpl
 		if (!purple_account_get_remember_password(account))
 			purple_account_set_password(account, NULL);
 
-		msg = g_strdup(_("Incorrect password."));
+		msg = g_strdup(_("Incorrect password"));
 		reason = PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED;
 		break;
 	case 14:
@@ -2166,10 +2166,10 @@ static void yahoo_process_addbuddy(Purpl
 	}
 
 	decoded_group = yahoo_string_decode(gc, group, FALSE);
-	buf = g_strdup_printf(_("Could not add buddy %s to group %s to the server list on account %s."),
+	buf = g_strdup_printf(_("Unable to add buddy %s to group %s to the server list on account %s."),
 				who, decoded_group, purple_connection_get_display_name(gc));
 	if (!purple_conv_present_error(who, purple_connection_get_account(gc), buf))
-		purple_notify_error(gc, NULL, _("Could not add buddy to server list"), buf);
+		purple_notify_error(gc, NULL, _("Unable to add buddy to server list"), buf);
 	g_free(buf);
 	g_free(decoded_group);
 	g_free(who);
@@ -2928,14 +2928,14 @@ static void yahoo_pending(gpointer data,
 			/* No worries */
 			return;
 
-		tmp = g_strdup_printf(_("Lost connection with server:\n%s"),
+		tmp = g_strdup_printf(_("Lost connection with server: %s"),
 				g_strerror(errno));
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
 		return;
 	} else if (len == 0) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-				_("Server closed the connection."));
+				_("Server closed the connection"));
 		return;
 	}
 	gc->last_received = time(NULL);
@@ -3017,8 +3017,7 @@ static void yahoo_got_connected(gpointer
 
 	if (source < 0) {
 		gchar *tmp;
-		tmp = g_strdup_printf(_("Could not establish a connection with the server:\n%s"),
-				error_message);
+		tmp = g_strdup_printf(_("Unable to connect: %s"), error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
 		return;
@@ -3044,8 +3043,7 @@ static void yahoo_got_web_connected(gpoi
 
 	if (source < 0) {
 		gchar *tmp;
-		tmp = g_strdup_printf(_("Could not establish a connection with the server:\n%s"),
-				error_message);
+		tmp = g_strdup_printf(_("Unable to connect: %s"), error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
 		return;
@@ -3084,14 +3082,14 @@ static void yahoo_web_pending(gpointer d
 			/* No worries */
 			return;
 
-		tmp = g_strdup_printf(_("Lost connection with server:\n%s"),
+		tmp = g_strdup_printf(_("Lost connection with server: %s"),
 				g_strerror(errno));
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
 		return;
 	} else if (len == 0) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Server closed the connection."));
+				_("Server closed the connection"));
 		return;
 	}
 
@@ -3107,7 +3105,7 @@ static void yahoo_web_pending(gpointer d
 	if ((strncmp(buf, "HTTP/1.0 302", strlen("HTTP/1.0 302")) &&
 			  strncmp(buf, "HTTP/1.1 302", strlen("HTTP/1.1 302")))) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			_("Received unexpected HTTP response from server."));
+			_("Received unexpected HTTP response from server"));
 		purple_debug_misc("yahoo", "Unexpected HTTP response: %s\n", buf);
 		return;
 	}
@@ -3137,7 +3135,7 @@ static void yahoo_web_pending(gpointer d
 	                         purple_account_get_int(account, "port", YAHOO_PAGER_PORT),
 	                         yahoo_got_web_connected, gc) == NULL) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		                               _("Connection problem"));
+		                               _("Unable to connect"));
 		return;
 	}
 }
@@ -3163,7 +3161,7 @@ static void yahoo_got_cookies_send_cb(gp
 		if (gc->inpa)
 			purple_input_remove(gc->inpa);
 		gc->inpa = 0;
-		tmp = g_strdup_printf(_("Lost connection with %s:\n%s"),
+		tmp = g_strdup_printf(_("Lost connection with %s: %s"),
 				"login.yahoo.com:80", g_strerror(errno));
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
@@ -3188,7 +3186,7 @@ static void yahoo_got_cookies(gpointer d
 
 	if (source < 0) {
 		gchar *tmp;
-		tmp = g_strdup_printf(_("Could not establish a connection with %s:\n%s"),
+		tmp = g_strdup_printf(_("Unable to establish a connection with %s: %s"),
 				"login.yahoo.com:80", error_message);
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
 		g_free(tmp);
@@ -3325,7 +3323,7 @@ yahoo_login_page_cb(PurpleUtilFetchUrlDa
 	yd->auth = g_string_free(url, FALSE);
 	if (purple_proxy_connect(gc, account, "login.yahoo.com", 80, yahoo_got_cookies, gc) == NULL) {
 		purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-		                               _("Connection problem"));
+		                               _("Unable to connect"));
 		return;
 	}
 
@@ -3436,7 +3434,7 @@ static void yahoo_login(PurpleAccount *a
 		                       yahoo_got_connected, gc) == NULL)
 		{
 			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			                               _("Connection problem"));
+			                               _("Unable to connect"));
 			return;
 		}
 	} else {
@@ -3447,7 +3445,7 @@ static void yahoo_login(PurpleAccount *a
 		                       yahoo_got_connected, gc) == NULL)
 		{
 			purple_connection_error_reason(gc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			                               _("Connection problem"));
+			                               _("Unable to connect"));
 			return;
 		}
 	}
============================================================
--- libpurple/protocols/yahoo/ycht.c	4d48bacf406d1af0bcd523532682f05dffece5ed
+++ libpurple/protocols/yahoo/ycht.c	bfafee6d47a25ecbf3c5ec3b9f1bb471e95cf671
@@ -285,9 +285,11 @@ static void ycht_packet_send_write_cb(gp
 	else if (ret <= 0) {
 		/* TODO: error handling */
 /*
+		gchar *tmp = g_strdup_printf(_("Lost connection with server: %s"),
+				g_strerror(errno));
 		purple_connection_error_reason(purple_account_get_connection(irc->account),
-			      PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
-			      _("Server has disconnected"));
+			      PURPLE_CONNECTION_ERROR_NETWORK_ERROR, tmp);
+		g_free(tmp);
 */
 		return;
 	}
@@ -454,7 +456,7 @@ static void ycht_connection_error(YchtCo
 static void ycht_connection_error(YchtConn *ycht, const gchar *error)
 {
 
-	purple_notify_info(ycht->gc, NULL, _("Connection problem with the YCHT server."), error);
+	purple_notify_info(ycht->gc, NULL, _("Connection problem with the YCHT server"), error);
 	ycht_connection_close(ycht);
 }
 
@@ -473,13 +475,13 @@ static void ycht_pending(gpointer data, 
 			/* No worries */
 			return;
 
-		tmp = g_strdup_printf(_("Lost connection with server\n%s"),
+		tmp = g_strdup_printf(_("Lost connection with server: %s"),
 				g_strerror(errno));
 		ycht_connection_error(ycht, tmp);
 		g_free(tmp);
 		return;
 	} else if (len == 0) {
-		ycht_connection_error(ycht, _("Server closed the connection."));
+		ycht_connection_error(ycht, _("Server closed the connection"));
 		return;
 	}
 
@@ -546,7 +548,7 @@ static void ycht_got_connected(gpointer 
 	char *buf;
 
 	if (source < 0) {
-		ycht_connection_error(ycht, _("Unable to connect."));
+		ycht_connection_error(ycht, _("Unable to connect"));
 		return;
 	}
 
@@ -582,7 +584,7 @@ void ycht_connection_open(PurpleConnecti
 	                       purple_account_get_int(account, "ycht-port", YAHOO_YCHT_PORT),
 	                       ycht_got_connected, ycht) == NULL)
 	{
-		ycht_connection_error(ycht, _("Connection problem"));
+		ycht_connection_error(ycht, _("Unable to connect"));
 		return;
 	}
 }
============================================================
--- libpurple/proxy.c	56164fc5c945cc03f194d7d2ac7e805b98d63178
+++ libpurple/proxy.c	40b7bc8c37e9a9cd505a0e71557443c7e897ca50
@@ -2156,7 +2156,7 @@ connection_host_resolved(GSList *hosts, 
 
 	if (hosts == NULL)
 	{
-		purple_proxy_connect_data_disconnect(connect_data, _("Could not resolve host name"));
+		purple_proxy_connect_data_disconnect(connect_data, _("Unable to resolve hostname"));
 		return;
 	}
 


More information about the Commits mailing list