aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/oscar/oscar.c
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/oscar/oscar.c')
-rw-r--r--protocols/oscar/oscar.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/protocols/oscar/oscar.c b/protocols/oscar/oscar.c
index 5d23c36a..2d07f912 100644
--- a/protocols/oscar/oscar.c
+++ b/protocols/oscar/oscar.c
@@ -798,7 +798,9 @@ static int conninitdone_chat(aim_session_t *sess, aim_frame_t *fr, ...) {
chatcon = find_oscar_chat_by_conn(ic, fr->conn);
chatcon->id = id;
- chatcon->cnv = imcb_chat_new(ic, chatcon->show);
+ chatcon->cnv = bee_chat_by_title(ic->bee, ic, chatcon->show);
+ if (chatcon->cnv == NULL)
+ chatcon->cnv = imcb_chat_new(ic, chatcon->show);
chatcon->cnv->data = chatcon;
return 1;
@@ -1189,8 +1191,7 @@ static void gaim_icq_authgrant(void *data_) {
message = 0;
aim_ssi_auth_reply(od->sess, od->conn, uin, 1, "");
// aim_send_im_ch4(od->sess, uin, AIM_ICQMSG_AUTHGRANTED, &message);
- if(imcb_find_buddy(data->ic, uin) == NULL)
- imcb_ask_add(data->ic, uin, NULL);
+ imcb_ask_add(data->ic, uin, NULL);
g_free(uin);
g_free(data);
@@ -1951,11 +1952,13 @@ static void oscar_get_info(struct im_connection *g, char *name) {
static void oscar_get_away(struct im_connection *g, char *who) {
struct oscar_data *odata = (struct oscar_data *)g->proto_data;
if (odata->icq) {
+ /** FIXME(wilmer): Hmm, lost the ability to get away msgs here, do we care to get that back?
struct buddy *budlight = imcb_find_buddy(g, who);
if (budlight)
if ((budlight->uc & 0xff80) >> 7)
if (budlight->caps & AIM_CAPS_ICQSERVERRELAY)
aim_send_im_ch2_geticqmessage(odata->sess, who, (budlight->uc & 0xff80) >> 7);
+ */
} else
aim_getinfo(odata->sess, odata->conn, who, AIM_GETINFO_AWAYMESSAGE);
}
@@ -2093,7 +2096,7 @@ static int gaim_ssi_parselist(aim_session_t *sess, aim_frame_t *fr, ...) {
switch (curitem->type) {
case 0x0000: /* Buddy */
- if ((curitem->name) && (!imcb_find_buddy(ic, nrm))) {
+ if ((curitem->name) && (!imcb_buddy_by_handle(ic, nrm))) {
char *realname = NULL;
if (curitem->data && aim_gettlv(curitem->data, 0x0131, 1))
@@ -2649,12 +2652,13 @@ struct groupchat *oscar_chat_with(struct im_connection * ic, char *who)
struct groupchat *ret;
static int chat_id = 0;
char * chatname;
+ struct groupchat *c;
chatname = g_strdup_printf("%s%s_%d", isdigit(*ic->acc->user) ? "icq_" : "",
ic->acc->user, chat_id++);
-
+
+ c = imcb_chat_new(ic, chatname);
ret = oscar_chat_join(ic, chatname, NULL, NULL);
-
aim_chat_invite(od->sess, od->conn, who, "", 4, chatname, 0x0);
g_free(chatname);