Ignore:
Timestamp:
2011-12-24T18:09:05Z (12 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
9a1c14d
Parents:
164352e
Message:

Slight cleanup: Use a constant instead of just "jabber_oauth" everywhere,
and added some safeguards to keep the user from messaging it when we're
not actually doing OAuth setup.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/jabber/jabber.c

    r164352e r34ded90  
    9090        s = set_add( &acc->set, "tls_verify", "true", set_eval_bool, acc );
    9191        s->flags |= ACC_SET_OFFLINE_ONLY;
    92        
     92
    9393        s = set_add( &acc->set, "user_agent", "BitlBee", NULL, acc );
    9494       
     
    337337                return jabber_write( ic, message, strlen( message ) );
    338338       
    339         if( g_strcasecmp( who, "jabber_oauth" ) == 0 )
     339        if( g_strcasecmp( who, JABBER_OAUTH_HANDLE ) == 0 &&
     340            !( jd->flags & OPT_LOGGED_IN ) && jd->fd == -1 )
    340341        {
    341342                if( sasl_oauth2_get_refresh_token( ic, message ) )
Note: See TracChangeset for help on using the changeset viewer.