Ignore:
Timestamp:
2009-10-17T17:24:52Z (15 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
c48a033
Parents:
0c41177 (diff), 2e44b1f (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merging BitlBee 1.2.4.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/jabber/conference.c

    r0c41177 rc5bc47b  
    2626static xt_status jabber_chat_join_failed( struct im_connection *ic, struct xt_node *node, struct xt_node *orig );
    2727
    28 struct groupchat *jabber_chat_join( struct im_connection *ic, char *room, char *nick, char *password )
     28struct groupchat *jabber_chat_join( struct im_connection *ic, const char *room, const char *nick, const char *password )
    2929{
    3030        struct jabber_chat *jc;
     
    3636        node = xt_new_node( "x", NULL, NULL );
    3737        xt_add_attr( node, "xmlns", XMLNS_MUC );
    38         node = jabber_make_packet( "presence", NULL, roomjid, node );
    3938        if( password )
    4039                xt_add_child( node, xt_new_node( "password", password, NULL ) );
     40        node = jabber_make_packet( "presence", NULL, roomjid, node );
    4141        jabber_cache_add( ic, node, jabber_chat_join_failed );
    4242       
     
    234234                            ( strcmp( s, XMLNS_MUC_USER ) == 0 ) )
    235235                        {
    236                                 c = xt_find_node( c->children, "item" );
    237                                 if( ( s = xt_find_attr( c, "jid" ) ) )
     236                                struct xt_node *item;
     237                               
     238                                item = xt_find_node( c->children, "item" );
     239                                if( ( s = xt_find_attr( item, "jid" ) ) )
    238240                                {
    239241                                        /* Yay, found what we need. :-) */
     
    283285        else if( type ) /* type can only be NULL or "unavailable" in this function */
    284286        {
    285                 s = strchr( bud->ext_jid, '/' );
    286                 if( s ) *s = 0;
    287                 imcb_chat_remove_buddy( chat, bud->ext_jid, NULL );
    288                 if( bud != jc->me && bud->flags & JBFLAG_IS_ANONYMOUS )
    289                         imcb_remove_buddy( ic, bud->ext_jid, NULL );
    290                 if( s ) *s = '/';
     287                if( ( bud->flags & JBFLAG_IS_CHATROOM ) && bud->ext_jid )
     288                {
     289                        s = strchr( bud->ext_jid, '/' );
     290                        if( s ) *s = 0;
     291                        imcb_chat_remove_buddy( chat, bud->ext_jid, NULL );
     292                        if( bud != jc->me && bud->flags & JBFLAG_IS_ANONYMOUS )
     293                                imcb_remove_buddy( ic, bud->ext_jid, NULL );
     294                        if( s ) *s = '/';
     295                }
    291296               
    292297                if( bud == jc->me )
Note: See TracChangeset for help on using the changeset viewer.