From 78e2eb7bdaf0ab00321f47b93b37b603ef32bdb0 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Sat, 24 Jul 2010 13:15:43 +0200 Subject: New handling of authorization requests. The old one wasn't fully broken actually, but it needed a reconnect to see new contacts. --- protocols/yahoo/Makefile | 2 +- protocols/yahoo/yahoo.c | 15 +++------------ 2 files changed, 4 insertions(+), 13 deletions(-) (limited to 'protocols') diff --git a/protocols/yahoo/Makefile b/protocols/yahoo/Makefile index 20ecce71..e5374538 100644 --- a/protocols/yahoo/Makefile +++ b/protocols/yahoo/Makefile @@ -14,7 +14,7 @@ endif # [SH] Program variables objects = yahoo.o crypt.o libyahoo2.o yahoo_fn.o yahoo_httplib.o yahoo_util.o -CFLAGS += -Wall -DSTDC_HEADERS -DHAVE_STRING_H -DHAVE_STRCHR -DHAVE_MEMCPY -DHAVE_GLIB +CFLAGS += -Wall -DSTDC_HEADERS -DHAVE_STRING_H -DHAVE_STRCHR -DHAVE_MEMCPY -DHAVE_GLIB -Wno-pointer-to-int-cast LFLAGS += -r # [SH] Phony targets diff --git a/protocols/yahoo/yahoo.c b/protocols/yahoo/yahoo.c index 7a856254..1ace6020 100644 --- a/protocols/yahoo/yahoo.c +++ b/protocols/yahoo/yahoo.c @@ -338,20 +338,16 @@ static struct groupchat *byahoo_chat_with( struct im_connection *ic, char *who ) static void byahoo_auth_allow( struct im_connection *ic, const char *who ) { - /* struct byahoo_data *yd = (struct byahoo_data *) ic->proto_data; - yahoo_accept_buddy_ymsg13( yd->y2_id, NULL, who ); - */ + yahoo_confirm_buddy( yd->y2_id, who, 0, "" ); } static void byahoo_auth_deny( struct im_connection *ic, const char *who ) { - /* struct byahoo_data *yd = (struct byahoo_data *) ic->proto_data; - yahoo_reject_buddy_ymsg13( yd->y2_id, NULL, who, NULL ); - */ + yahoo_confirm_buddy( yd->y2_id, who, 1, "" ); } void byahoo_initmodule( ) @@ -928,16 +924,11 @@ void ext_yahoo_chat_yahooerror( int id, const char *me ) { } -void ext_yahoo_contact_auth_request( int id, const char *myid, const char *who, const char *msg ) -{ - /* Apparently no longer implemented.. */ -} - void ext_yahoo_contact_added( int id, const char *myid, const char *who, const char *msg ) { struct im_connection *ic = byahoo_get_ic_by_id( id ); - imcb_add_buddy( ic, (char*) who, NULL ); + imcb_ask_auth( ic, who, msg ); } void ext_yahoo_rejected( int id, const char *who, const char *msg ) -- cgit v1.2.3