diff options
author | Wilmer van der Gaast <wilmer@gaast.net> | 2010-08-21 18:27:32 +0100 |
---|---|---|
committer | Wilmer van der Gaast <wilmer@gaast.net> | 2010-08-21 18:27:32 +0100 |
commit | 327af51a28fe292cfc4a68caa086a13175a69719 (patch) | |
tree | 09a83946fb22e8577dede332676a7c5f4c7d5d8c /protocols | |
parent | a366cca62d3a55db4f12a94584f7e7f8fa00db02 (diff) |
Some general cleanup, plus fixing a bug in the memberlist parsing code:
the lists can come in in any order, so parse it *completely* before showing
auth requests.
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/msn/soap.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/protocols/msn/soap.c b/protocols/msn/soap.c index e67da2a1..8d276108 100644 --- a/protocols/msn/soap.c +++ b/protocols/msn/soap.c @@ -553,17 +553,11 @@ static xt_status msn_soap_memlist_member( struct xt_node *node, gpointer data ) else if( strcmp( role, "Block" ) == 0 ) bd->flags |= MSN_BUDDY_BL; else if( strcmp( role, "Reverse" ) == 0 ) - { bd->flags |= MSN_BUDDY_RL; - msn_buddy_ask( bu ); - } else if( strcmp( role, "Pending" ) == 0 ) - { bd->flags |= MSN_BUDDY_PL; - msn_buddy_ask( bu ); - } - printf( "%s %d\n", handle, bd->flags ); + printf( "%p %s %d\n", bu, handle, bd->flags ); return XT_HANDLED; } @@ -782,7 +776,18 @@ static const struct xt_handler_entry msn_soap_addressbook_parser[] = { static int msn_soap_addressbook_handle_response( struct msn_soap_req_data *soap_req ) { + GSList *l; + + for( l = soap_req->ic->bee->users; l; l = l->next ) + { + struct bee_user *bu = l->data; + + if( bu->ic == soap_req->ic ) + msn_buddy_ask( bu ); + } + msn_auth_got_contact_list( soap_req->ic ); + return MSN_SOAP_OK; } |