diff options
Diffstat (limited to 'protocols/oscar')
| -rw-r--r-- | protocols/oscar/chat.c | 6 | ||||
| -rw-r--r-- | protocols/oscar/chatnav.c | 10 | ||||
| -rw-r--r-- | protocols/oscar/icq.c | 2 | ||||
| -rw-r--r-- | protocols/oscar/im.c | 8 | ||||
| -rw-r--r-- | protocols/oscar/info.c | 6 | ||||
| -rw-r--r-- | protocols/oscar/oscar.c | 122 | ||||
| -rw-r--r-- | protocols/oscar/rxqueue.c | 2 | ||||
| -rw-r--r-- | protocols/oscar/search.c | 2 | ||||
| -rw-r--r-- | protocols/oscar/service.c | 4 | ||||
| -rw-r--r-- | protocols/oscar/txqueue.c | 8 | 
10 files changed, 78 insertions, 92 deletions
| diff --git a/protocols/oscar/chat.c b/protocols/oscar/chat.c index df535c4f..82aa5421 100644 --- a/protocols/oscar/chat.c +++ b/protocols/oscar/chat.c @@ -53,7 +53,7 @@ aim_conn_t *aim_chat_getconn(aim_session_t *sess, const char *name)  		if (cur->type != AIM_CONN_TYPE_CHAT)  			continue;  		if (!cur->priv) { -			do_error_dialog(sess->aux_data, "chat connection with no name!", "Gaim"); +			imc_error(sess->aux_data, "chat connection with no name!");  			continue;  		} @@ -396,7 +396,7 @@ static int infoupdate(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, a  	detaillevel = aimbs_get8(bs);  	if (detaillevel != 0x02) { -		do_error_dialog(sess->aux_data, "Only detaillevel 0x2 is support at the moment", "Gaim"); +		imc_error(sess->aux_data, "Only detaillevel 0x2 is support at the moment");  		return 1;  	} @@ -614,7 +614,7 @@ static int incomingmsg(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx,  	channel = aimbs_get16(bs);  	if (channel != 0x0003) { -		do_error_dialog(sess->aux_data, "unknown channel!", "Gaim"); +		imc_error(sess->aux_data, "unknown channel!");  		return 0;  	} diff --git a/protocols/oscar/chatnav.c b/protocols/oscar/chatnav.c index c7e11765..05fdf6fa 100644 --- a/protocols/oscar/chatnav.c +++ b/protocols/oscar/chatnav.c @@ -285,7 +285,7 @@ static int parseinfo_create(aim_session_t *sess, aim_module_t *mod, aim_frame_t  	tlvlist = aim_readtlvchain(bs);  	if (!(bigblock = aim_gettlv(tlvlist, 0x0004, 1))) { -		do_error_dialog(sess->aux_data, "no bigblock in top tlv in create room response", "Gaim"); +		imc_error(sess->aux_data, "no bigblock in top tlv in create room response");  		aim_freetlvchain(&tlvlist);  		return 0; @@ -300,7 +300,7 @@ static int parseinfo_create(aim_session_t *sess, aim_module_t *mod, aim_frame_t  	detaillevel = aimbs_get8(&bbbs);  	if (detaillevel != 0x02) { -		do_error_dialog(sess->aux_data, "unknown detaillevel in create room response", "Gaim"); +		imc_error(sess->aux_data, "unknown detaillevel in create room response");  		aim_freetlvchain(&tlvlist);  		g_free(ck);  		return 0; @@ -366,12 +366,12 @@ static int parseinfo(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, ai  	int ret = 0;  	if (!(snac2 = aim_remsnac(sess, snac->id))) { -		do_error_dialog(sess->aux_data, "received response to unknown request!", "Gaim"); +		imc_error(sess->aux_data, "received response to unknown request!");  		return 0;  	}  	if (snac2->family != 0x000d) { -		do_error_dialog(sess->aux_data, "recieved response that maps to corrupt request!", "Gaim"); +		imc_error(sess->aux_data, "recieved response that maps to corrupt request!");  		return 0;  	} @@ -388,7 +388,7 @@ static int parseinfo(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, ai  	else if (snac2->type == 0x0008) /* create room */  		ret = parseinfo_create(sess, mod, rx, snac, bs, snac2);  	else -		do_error_dialog(sess->aux_data, "unknown request subtype", "Gaim"); +		imc_error(sess->aux_data, "unknown request subtype");  	if (snac2)  		g_free(snac2->data); diff --git a/protocols/oscar/icq.c b/protocols/oscar/icq.c index 23959b75..d3c7c182 100644 --- a/protocols/oscar/icq.c +++ b/protocols/oscar/icq.c @@ -239,7 +239,7 @@ static int icqresponse(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx,  	if (!(tl = aim_readtlvchain(bs)) || !(datatlv = aim_gettlv(tl, 0x0001, 1))) {  		aim_freetlvchain(&tl); -		do_error_dialog(sess->aux_data, "corrupt ICQ response\n", "Gaim"); +		imc_error(sess->aux_data, "corrupt ICQ response\n");  		return 0;  	} diff --git a/protocols/oscar/im.c b/protocols/oscar/im.c index bc2c2abe..ac3d08d4 100644 --- a/protocols/oscar/im.c +++ b/protocols/oscar/im.c @@ -936,7 +936,7 @@ static int outgoingim(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, a  	channel = aimbs_get16(bs);  	if (channel != 0x01) { -		do_error_dialog(sess->aux_data, "icbm: ICBM recieved on unsupported channel.  Ignoring.", "Gaim"); +		imc_error(sess->aux_data, "icbm: ICBM recieved on unsupported channel.  Ignoring.");  		return 0;  	} @@ -1344,7 +1344,7 @@ static int incomingim_ch1(aim_session_t *sess, aim_module_t *mod, aim_frame_t *r  			args.extdata = aimbs_getraw(bs, args.extdatalen);  		} else { -			// do_error_dialog(sess->aux_data, "Unknown TLV encountered", "Gaim"); +			// imc_error(sess->aux_data, "Unknown TLV encountered");  		}  		/* @@ -1516,7 +1516,7 @@ static int incomingim_ch2(aim_session_t *sess, aim_module_t *mod, aim_frame_t *r  	 */  	cookie2 = aimbs_getraw(&bbs, 8);  	if (memcmp(cookie, cookie2, 8) != 0)  -		do_error_dialog(sess->aux_data, "rend: warning cookies don't match!", "Gaim"); +		imc_error(sess->aux_data, "rend: warning cookies don't match!");  	memcpy(args.cookie, cookie2, 8);  	g_free(cookie2); @@ -1782,7 +1782,7 @@ static int incomingim(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, a  	} else { -		do_error_dialog(sess->aux_data, "ICBM received on an unsupported channel.  Ignoring.", "Gaim"); +		imc_error(sess->aux_data, "ICBM received on an unsupported channel.  Ignoring.");  		return 0;  	} diff --git a/protocols/oscar/info.c b/protocols/oscar/info.c index 0f1bcfd2..d1ed2059 100644 --- a/protocols/oscar/info.c +++ b/protocols/oscar/info.c @@ -473,7 +473,7 @@ int aim_extractuserinfo(aim_session_t *sess, aim_bstream_t *bs, aim_userinfo_t *  			 *  			 */  #ifdef DEBUG -			// do_error_dialog(sess->aux_data, G_STRLOC, "Unknown TLV encountered"); +			// imc_error(sess->aux_data, G_STRLOC);  #endif  		} @@ -634,7 +634,7 @@ static int userinfo(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim  	origsnac = aim_remsnac(sess, snac->id);  	if (!origsnac || !origsnac->data) { -		do_error_dialog(sess->aux_data, "major problem: no snac stored!", "Gaim"); +		imc_error(sess->aux_data, "major problem: no snac stored!");  		return 0;  	} @@ -643,7 +643,7 @@ static int userinfo(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim  	if ((inforeq->infotype != AIM_GETINFO_GENERALINFO) &&  			(inforeq->infotype != AIM_GETINFO_AWAYMESSAGE) &&  			(inforeq->infotype != AIM_GETINFO_CAPABILITIES)) { -		do_error_dialog(sess->aux_data, "unknown infotype in request!", "Gaim"); +		imc_error(sess->aux_data, "unknown infotype in request!");  		return 0;  	} diff --git a/protocols/oscar/oscar.c b/protocols/oscar/oscar.c index d2c6af1e..929b63d3 100644 --- a/protocols/oscar/oscar.c +++ b/protocols/oscar/oscar.c @@ -262,23 +262,21 @@ static gboolean oscar_callback(gpointer data, gint source,  		if (aim_get_command(odata->sess, conn) >= 0) {  			aim_rxdispatch(odata->sess);                                 if (odata->killme) -                                       signoff(ic); +                                       imc_logout(ic);  		} else {  			if ((conn->type == AIM_CONN_TYPE_BOS) ||  				   !(aim_getconn_type(odata->sess, AIM_CONN_TYPE_BOS))) { -				hide_login_progress_error(ic, _("Disconnected.")); -				signoff(ic); +				imc_error(ic, _("Disconnected.")); +				imc_logout(ic);  			} else if (conn->type == AIM_CONN_TYPE_CHAT) {  				struct chat_connection *c = find_oscar_chat_by_conn(ic, conn); -				char buf[BUF_LONG];  				c->conn = NULL;  				if (c->inpa > 0)  					b_event_remove(c->inpa);  				c->inpa = 0;  				c->fd = -1;  				aim_conn_kill(odata->sess, &conn); -				sprintf(buf, _("You have been disconnected from chat room %s."), c->name); -				do_error_dialog(sess->aux_data, buf, _("Chat Error!")); +				imc_error(sess->aux_data, _("You have been disconnected from chat room %s."), c->name);  			} else if (conn->type == AIM_CONN_TYPE_CHATNAV) {  				if (odata->cnpa > 0)  					b_event_remove(odata->cnpa); @@ -289,8 +287,7 @@ static gboolean oscar_callback(gpointer data, gint source,  					odata->create_rooms =  						g_slist_remove(odata->create_rooms, cr);  					g_free(cr); -					do_error_dialog(sess->aux_data, _("Chat is currently unavailable"), -							_("Gaim - Chat")); +					imc_error(sess->aux_data, _("Chat is currently unavailable"));  				}  				aim_conn_kill(odata->sess, &conn);  			} else if (conn->type == AIM_CONN_TYPE_AUTH) { @@ -327,8 +324,8 @@ static gboolean oscar_login_connect(gpointer data, gint source, b_input_conditio  	conn = aim_getconn_type_all(sess, AIM_CONN_TYPE_AUTH);  	if (source < 0) { -		hide_login_progress(ic, _("Couldn't connect to host")); -		signoff(ic); +		imc_error(ic, _("Couldn't connect to host")); +		imc_logout(ic);  		return FALSE;  	} @@ -355,8 +352,7 @@ static void oscar_init(account_t *acc)  static void oscar_login(account_t *acc) {  	aim_session_t *sess;  	aim_conn_t *conn; -	char buf[256]; -	struct im_connection *ic = new_gaim_conn(acc); +	struct im_connection *ic = imc_new(acc);  	struct oscar_data *odata = ic->proto_data = g_new0(struct oscar_data, 1);  	if (isdigit(acc->user[0])) { @@ -381,24 +377,23 @@ static void oscar_login(account_t *acc) {  	conn = aim_newconn(sess, AIM_CONN_TYPE_AUTH, NULL);  	if (conn == NULL) { -		hide_login_progress(ic, _("Unable to login to AIM")); -		signoff(ic); +		imc_error(ic, _("Unable to login to AIM")); +		imc_logout(ic);  		return;  	}  	if (acc->server == NULL) { -		hide_login_progress(ic, "No servername specified"); -		signoff(ic); +		imc_error(ic, "No servername specified"); +		imc_logout(ic);  		return;  	}  	if (g_strcasecmp(acc->server, "login.icq.com") != 0 &&  	    g_strcasecmp(acc->server, "login.oscar.aol.com") != 0) { -		serv_got_crap(ic, "Warning: Unknown OSCAR server: `%s'. Please review your configuration if the connection fails.",acc->server); +		imc_log(ic, "Warning: Unknown OSCAR server: `%s'. Please review your configuration if the connection fails.",acc->server);  	} -	g_snprintf(buf, sizeof(buf), _("Signon: %s"), ic->username); -	set_login_progress(ic, 2, buf); +	imc_log(ic, _("Signon: %s"), ic->username);  	aim_conn_addhandler(sess, conn, 0x0017, 0x0007, gaim_parse_login, 0);  	aim_conn_addhandler(sess, conn, 0x0017, 0x0003, gaim_parse_auth_resp, 0); @@ -406,8 +401,8 @@ static void oscar_login(account_t *acc) {  	conn->status |= AIM_CONN_STATUS_INPROGRESS;  	conn->fd = proxy_connect(acc->server, AIM_LOGIN_PORT, oscar_login_connect, ic);  	if (conn->fd < 0) { -		hide_login_progress(ic, _("Couldn't connect to host")); -		signoff(ic); +		imc_error(ic, _("Couldn't connect to host")); +		imc_logout(ic);  		return;  	}  	aim_request_login(sess, conn, ic->username); @@ -466,15 +461,15 @@ static gboolean oscar_bos_connect(gpointer data, gint source, b_input_condition  	bosconn = odata->conn;  	if (source < 0) { -		hide_login_progress(ic, _("Could Not Connect")); -		signoff(ic); +		imc_error(ic, _("Could Not Connect")); +		imc_logout(ic);  		return FALSE;  	}  	aim_conn_completeconnect(sess, bosconn);  	ic->inpa = b_input_add(bosconn->fd, GAIM_INPUT_READ,  			oscar_callback, bosconn); -	set_login_progress(ic, 4, _("Connection established, cookie sent")); +	imc_log(ic, _("Connection established, cookie sent"));  	return FALSE;  } @@ -497,23 +492,23 @@ static int gaim_parse_auth_resp(aim_session_t *sess, aim_frame_t *fr, ...) {  		switch (info->errorcode) {  		case 0x05:  			/* Incorrect nick/password */ -			hide_login_progress(ic, _("Incorrect nickname or password.")); +			imc_error(ic, _("Incorrect nickname or password."));  //			plugin_event(event_error, (void *)980, 0, 0, 0);  			break;  		case 0x11:  			/* Suspended account */ -			hide_login_progress(ic, _("Your account is currently suspended.")); +			imc_error(ic, _("Your account is currently suspended."));  			break;  		case 0x18:  			/* connecting too frequently */ -			hide_login_progress(ic, _("You have been connecting and disconnecting too frequently. Wait ten minutes and try again. If you continue to try, you will need to wait even longer.")); +			imc_error(ic, _("You have been connecting and disconnecting too frequently. Wait ten minutes and try again. If you continue to try, you will need to wait even longer."));  			break;  		case 0x1c:  			/* client too old */ -			hide_login_progress(ic, _("The client version you are using is too old. Please upgrade at " WEBSITE)); +			imc_error(ic, _("The client version you are using is too old. Please upgrade at " WEBSITE));  			break;  		default: -			hide_login_progress(ic, _("Authentication Failed")); +			imc_error(ic, _("Authentication Failed"));  			break;  		}  		od->killme = TRUE; @@ -525,7 +520,7 @@ static int gaim_parse_auth_resp(aim_session_t *sess, aim_frame_t *fr, ...) {  	bosconn = aim_newconn(sess, AIM_CONN_TYPE_BOS, NULL);  	if (bosconn == NULL) { -		hide_login_progress(ic, _("Internal Error")); +		imc_error(ic, _("Internal Error"));  		od->killme = TRUE;  		return 0;  	} @@ -571,7 +566,7 @@ static int gaim_parse_auth_resp(aim_session_t *sess, aim_frame_t *fr, ...) {  	bosconn->fd = proxy_connect(host, port, oscar_bos_connect, ic);  	g_free(host);  	if (bosconn->fd < 0) { -		hide_login_progress(ic, _("Could Not Connect")); +		imc_error(ic, _("Could Not Connect"));  		od->killme = TRUE;  		return 0;  	} @@ -609,8 +604,8 @@ static gboolean damn_you(gpointer data, gint source, b_input_condition c)  		in = '\0';  	}  	if (in != '\n') { -		do_error_dialog(pos->ic, "Gaim was unable to get a valid hash for logging into AIM." -				" You may be disconnected shortly.", "Login Error"); +		imc_error(pos->ic, "Gaim was unable to get a valid hash for logging into AIM." +				" You may be disconnected shortly.");  		b_event_remove(pos->inpa);  		closesocket(pos->fd);  		g_free(pos); @@ -632,8 +627,8 @@ static gboolean straight_to_hell(gpointer data, gint source, b_input_condition c  	char buf[BUF_LONG];  	if (source < 0) { -		do_error_dialog(pos->ic, "Gaim was unable to get a valid hash for logging into AIM." -				" You may be disconnected shortly.", "Login Error"); +		imc_error(pos->ic, "Gaim was unable to get a valid hash for logging into AIM." +				" You may be disconnected shortly.");  		if (pos->modname)  			g_free(pos->modname);  		g_free(pos); @@ -710,8 +705,8 @@ int gaim_memrequest(aim_session_t *sess, aim_frame_t *fr, ...) {  		if (pos->modname)  			g_free(pos->modname);  		g_free(pos); -		do_error_dialog(sess->aux_data, "Gaim was unable to get a valid hash for logging into AIM." -				" You may be disconnected shortly.", "Login Error"); +		imc_error(sess->aux_data, "Gaim was unable to get a valid hash for logging into AIM." +				" You may be disconnected shortly.");  	}  	pos->fd = fd; @@ -1209,11 +1204,11 @@ static int incomingim_chan4(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_  		} break;  		case 0x0007: { /* Someone has denied you authorization */ -			serv_got_crap(sess->aux_data, "The user %u has denied your request to add them to your contact list for the following reason:\n%s", args->uin, args->msg ? args->msg : _("No reason given.") ); +			imc_log(sess->aux_data, "The user %u has denied your request to add them to your contact list for the following reason:\n%s", args->uin, args->msg ? args->msg : _("No reason given.") );  		} break;  		case 0x0008: { /* Someone has granted you authorization */ -			serv_got_crap(sess->aux_data, "The user %u has granted your request to add them to your contact list for the following reason:\n%s", args->uin, args->msg ? args->msg : _("No reason given.") ); +			imc_log(sess->aux_data, "The user %u has granted your request to add them to your contact list for the following reason:\n%s", args->uin, args->msg ? args->msg : _("No reason given.") );  		} break;  		case 0x0012: { @@ -1338,7 +1333,7 @@ static int gaim_parse_misses(aim_session_t *sess, aim_frame_t *fr, ...) {  				   userinfo->sn);  			break;  	} -	do_error_dialog(sess->aux_data, buf, _("Gaim - Error")); +	imc_error(sess->aux_data, buf);  	return 1;  } @@ -1346,16 +1341,13 @@ static int gaim_parse_misses(aim_session_t *sess, aim_frame_t *fr, ...) {  static int gaim_parse_genericerr(aim_session_t *sess, aim_frame_t *fr, ...) {  	va_list ap;  	guint16 reason; -	char *m;  	va_start(ap, fr);  	reason = (guint16)va_arg(ap, unsigned int);  	va_end(ap); -	m = g_strdup_printf(_("SNAC threw error: %s\n"), -			reason < msgerrreasonlen ? msgerrreason[reason] : "Unknown error"); -	do_error_dialog(sess->aux_data, m, _("Gaim - Oscar SNAC Error")); -	g_free(m); +	imc_error(sess->aux_data, _("SNAC threw error: %s"), +	          reason < msgerrreasonlen ? msgerrreason[reason] : "Unknown error");  	return 1;  } @@ -1364,16 +1356,14 @@ static int gaim_parse_msgerr(aim_session_t *sess, aim_frame_t *fr, ...) {  	va_list ap;  	char *destn;  	guint16 reason; -	char buf[1024];  	va_start(ap, fr);  	reason = (guint16)va_arg(ap, unsigned int);  	destn = va_arg(ap, char *);  	va_end(ap); -	sprintf(buf, _("Your message to %s did not get sent: %s"), destn, +	imc_error(sess->aux_data, _("Your message to %s did not get sent: %s"), destn,  			(reason < msgerrreasonlen) ? msgerrreason[reason] : _("Reason unknown")); -	do_error_dialog(sess->aux_data, buf, _("Gaim - Error"));  	return 1;  } @@ -1382,17 +1372,14 @@ static int gaim_parse_locerr(aim_session_t *sess, aim_frame_t *fr, ...) {  	va_list ap;  	char *destn;  	guint16 reason; -	char buf[1024];  	va_start(ap, fr);  	reason = (guint16)va_arg(ap, unsigned int);  	destn = va_arg(ap, char *);  	va_end(ap); -	sprintf(buf, _("User information for %s unavailable: %s"), destn, +	imc_error(sess->aux_data, _("User information for %s unavailable: %s"), destn,  			(reason < msgerrreasonlen) ? msgerrreason[reason] : _("Reason unknown")); -	do_error_dialog(sess->aux_data, buf, _("Gaim - Error")); -  	return 1;  } @@ -1408,8 +1395,7 @@ static int gaim_parse_motd(aim_session_t *sess, aim_frame_t *fr, ...) {  	va_end(ap);  	if (id < 4) -		do_error_dialog(sess->aux_data, _("Your connection may be lost."), -				_("AOL error")); +		imc_error(sess->aux_data, _("Your connection may be lost."));  	return 1;  } @@ -1603,8 +1589,8 @@ static int gaim_parse_ratechange(aim_session_t *sess, aim_frame_t *fr, ...) {  	} else if (code == AIM_RATE_CODE_WARNING) {  		aim_conn_setlatency(fr->conn, windowsize/4);  	} else if (code == AIM_RATE_CODE_LIMIT) { -		do_error_dialog(sess->aux_data, _("The last message was not sent because you are over the rate limit. " -				  "Please wait 10 seconds and try again."), _("Gaim - Error")); +		imc_error(sess->aux_data, _("The last message was not sent because you are over the rate limit. " +			  "Please wait 10 seconds and try again."));  		aim_conn_setlatency(fr->conn, windowsize/2);  	} else if (code == AIM_RATE_CODE_CLEARLIMIT) {  		aim_conn_setlatency(fr->conn, 0); @@ -1808,11 +1794,11 @@ static int gaim_offlinemsg(aim_session_t *sess, aim_frame_t *fr, ...) {  		} break;  		case 0x0007: { /* Someone has denied you authorization */ -			serv_got_crap(sess->aux_data, "The user %u has denied your request to add them to your contact list for the following reason:\n%s", msg->sender, msg->msg ? msg->msg : _("No reason given.") ); +			imc_log(sess->aux_data, "The user %u has denied your request to add them to your contact list for the following reason:\n%s", msg->sender, msg->msg ? msg->msg : _("No reason given.") );  		} break;  		case 0x0008: { /* Someone has granted you authorization */ -			serv_got_crap(sess->aux_data, "The user %u has granted your request to add them to your contact list for the following reason:\n%s", msg->sender, msg->msg ? msg->msg : _("No reason given.") ); +			imc_log(sess->aux_data, "The user %u has granted your request to add them to your contact list for the following reason:\n%s", msg->sender, msg->msg ? msg->msg : _("No reason given.") );  		} break;  		case 0x0012: { @@ -1925,7 +1911,7 @@ static void oscar_set_away_aim(struct im_connection *ic, struct oscar_data *od,  	} /* else... */  	if (od->rights.maxawaymsglen == 0) -		do_error_dialog(ic, "oscar_set_away_aim called before locate rights received", "Protocol Error"); +		imc_error(ic, "oscar_set_away_aim called before locate rights received");  	aim_setextstatus(od->sess, od->conn, AIM_ICQ_STATE_NORMAL); @@ -1943,7 +1929,7 @@ static void oscar_set_away_aim(struct im_connection *ic, struct oscar_data *od,  		errstr = g_strdup_printf("Maximum away message length of %d bytes exceeded, truncating", od->rights.maxawaymsglen); -		do_error_dialog(ic, errstr, "Away Message Too Long"); +		imc_error(ic, errstr);  		g_free(errstr);  	} @@ -2109,7 +2095,7 @@ static int gaim_ssi_parselist(aim_session_t *sess, aim_frame_t *fr, ...) {  	aim_icq_reqofflinemsgs(sess);  	/* Now that we have a buddy list, we can tell BitlBee that we're online. */ -	account_online(ic); +	imc_connected(ic);  	return 1;  } @@ -2131,7 +2117,7 @@ static int gaim_ssi_parseack( aim_session_t *sess, aim_frame_t *fr, ... )  		if( count & 1 )  		{  			/* Hmm, the length should be even... */ -			do_error_dialog( sess->aux_data, "Received SSI ACK package with non-even length", "Gaim - Error" ); +			imc_error( sess->aux_data, "Received SSI ACK package with non-even length");  			return( 0 );  		}  		count >>= 1; @@ -2142,7 +2128,7 @@ static int gaim_ssi_parseack( aim_session_t *sess, aim_frame_t *fr, ... )  			st = aimbs_get16( &fr->data );  			if( st == 0x0E )  			{ -				serv_got_crap( sess->aux_data, "Buddy %s can't be added without authorization, requesting authorization", list ); +				imc_log( sess->aux_data, "Buddy %s can't be added without authorization, requesting authorization", list );  				aim_ssi_auth_request( sess, fr->conn, list, "" );  				aim_ssi_addbuddies( sess, fr->conn, OSCAR_GROUP, &list, 1, 1 ); @@ -2329,7 +2315,7 @@ static int gaim_icqinfo(aim_session_t *sess, aim_frame_t *fr, ...)                  g_string_sprintfa(str, "\n");          } -		serv_got_crap(ic, "%s\n%s", _("User Info"), str->str); +		imc_log(ic, "%s\n%s", _("User Info"), str->str);          g_string_free(str, TRUE);          return 1; @@ -2423,18 +2409,18 @@ static int gaim_parseaiminfo(aim_session_t *sess, aim_frame_t *fr, ...)  			idletime.tm_min = userinfo->idletime % 60;  			idletime.tm_sec = 0;  			strftime(buff, 256, _("%d days %H hours %M minutes"), &idletime); -			serv_got_crap(ic, "%s: %s", _("Idle Time"), buff); +			imc_log(ic, "%s: %s", _("Idle Time"), buff);  		}  		if(text) {  			utf8 = oscar_encoding_to_utf8(extracted_encoding, text, text_length); -			serv_got_crap(ic, "%s\n%s", _("User Info"), utf8); +			imc_log(ic, "%s\n%s", _("User Info"), utf8);  		} else { -			serv_got_crap(ic, _("No user info available.")); +			imc_log(ic, _("No user info available."));  		}  	} else if(infotype == AIM_GETINFO_AWAYMESSAGE && userinfo->flags & AIM_FLAG_AWAY) {  		utf8 = oscar_encoding_to_utf8(extracted_encoding, text, text_length); -		serv_got_crap(ic, "%s\n%s", _("Away Message"), utf8); +		imc_log(ic, "%s\n%s", _("Away Message"), utf8);  	}  	g_free(utf8); diff --git a/protocols/oscar/rxqueue.c b/protocols/oscar/rxqueue.c index 6e8dd29c..b5a83be8 100644 --- a/protocols/oscar/rxqueue.c +++ b/protocols/oscar/rxqueue.c @@ -391,7 +391,7 @@ int aim_get_command(aim_session_t *sess, aim_conn_t *conn)  		aim_bstream_rewind(&flaphdr);  		start = aimbs_get8(&flaphdr); -		do_error_dialog(sess->aux_data, "FLAP framing disrupted", "Gaim"); +		imc_error(sess->aux_data, "FLAP framing disrupted");  		aim_conn_close(conn);  		return -1;  	}	 diff --git a/protocols/oscar/search.c b/protocols/oscar/search.c index 9685a3d1..c557e35f 100644 --- a/protocols/oscar/search.c +++ b/protocols/oscar/search.c @@ -38,7 +38,7 @@ static int error(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_mo  	/* XXX the modules interface should have already retrieved this for us */  	if (!(snac2 = aim_remsnac(sess, snac->id))) { -		do_error_dialog(sess->aux_data, "couldn't get snac", "Gaim"); +		imc_error(sess->aux_data, "couldn't get snac");  		return 0;  	} diff --git a/protocols/oscar/service.c b/protocols/oscar/service.c index 2a3dd1fb..69d53d00 100644 --- a/protocols/oscar/service.c +++ b/protocols/oscar/service.c @@ -566,7 +566,7 @@ static int migrate(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_  		group = aimbs_get16(bs); -		do_error_dialog(sess->aux_data, "bifurcated migration unsupported", "Gaim"); +		imc_error(sess->aux_data, "bifurcated migration unsupported");  	}  	tl = aim_readtlvchain(bs); @@ -893,7 +893,7 @@ int aim_sendmemblock(aim_session_t *sess, aim_conn_t *conn, guint32 offset, guin  			aimbs_put32(&fr->data, 0xecf8427e);  */  		} else -			do_error_dialog(sess->aux_data, "WARNING: unknown hash request", "Gaim"); +			imc_error(sess->aux_data, "WARNING: unknown hash request");  	} diff --git a/protocols/oscar/txqueue.c b/protocols/oscar/txqueue.c index 6b4854c5..bd8db49d 100644 --- a/protocols/oscar/txqueue.c +++ b/protocols/oscar/txqueue.c @@ -29,7 +29,7 @@ aim_frame_t *aim_tx_new(aim_session_t *sess, aim_conn_t *conn, guint8 framing, g  	aim_frame_t *fr;  	if (!conn) { -		do_error_dialog(sess->aux_data, "no connection specified", "Gaim"); +		imc_error(sess->aux_data, "no connection specified");  		return NULL;  	} @@ -45,7 +45,7 @@ aim_frame_t *aim_tx_new(aim_session_t *sess, aim_conn_t *conn, guint8 framing, g  		fr->hdr.flap.type = chan;  	} else  -		do_error_dialog(sess->aux_data, "unknown framing", "Gaim"); +		imc_error(sess->aux_data, "unknown framing");  	if (datalen > 0) {  		guint8 *data; @@ -79,7 +79,7 @@ static int aim_tx_enqueue__queuebased(aim_session_t *sess, aim_frame_t *fr)  {  	if (!fr->conn) { -		do_error_dialog(sess->aux_data, "WARNING: enqueueing packet with no connection", "Gaim"); +		imc_error(sess->aux_data, "WARNING: enqueueing packet with no connection");  		fr->conn = aim_getconn_type(sess, AIM_CONN_TYPE_BOS);  	} @@ -119,7 +119,7 @@ static int aim_tx_enqueue__immediate(aim_session_t *sess, aim_frame_t *fr)  {  	if (!fr->conn) { -		do_error_dialog(sess->aux_data, "packet has no connection", "Gaim"); +		imc_error(sess->aux_data, "packet has no connection");  		aim_frame_destroy(fr);  		return 0;  	} | 
