Changeset fe7a554 for protocols/jabber/io.c
- Timestamp:
- 2006-09-22T18:39:31Z (18 years ago)
- Branches:
- master
- Children:
- d8e0484
- Parents:
- 8d74291
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/jabber/io.c
r8d74291 rfe7a554 219 219 struct gaim_connection *gc = data; 220 220 struct jabber_data *jd = gc->proto_data; 221 struct xt_node *c ;221 struct xt_node *c, *reply; 222 222 223 223 c = xt_find_node( node->children, "starttls" ); … … 231 231 } 232 232 233 if( ( c = xt_find_node( node->children, "bind" ) ) ) 234 { 235 reply = xt_new_node( "bind", NULL, xt_new_node( "resource", set_getstr( &gc->acc->set, "resource" ), NULL ) ); 236 xt_add_attr( reply, "xmlns", "urn:ietf:params:xml:ns:xmpp-bind" ); 237 reply = jabber_make_packet( "iq", "set", NULL, reply ); 238 jabber_cache_packet( gc, reply ); 239 240 if( !jabber_write_packet( gc, reply ) ) 241 return XT_ABORT; 242 243 jd->flags |= JFLAG_WAIT_BIND; 244 } 245 246 if( ( c = xt_find_node( node->children, "session" ) ) ) 247 { 248 reply = xt_new_node( "session", NULL, NULL ); 249 xt_add_attr( reply, "xmlns", "urn:ietf:params:xml:ns:xmpp-session" ); 250 reply = jabber_make_packet( "iq", "set", NULL, reply ); 251 jabber_cache_packet( gc, reply ); 252 253 if( !jabber_write_packet( gc, reply ) ) 254 return XT_ABORT; 255 256 jd->flags |= JFLAG_WAIT_SESSION; 257 } 258 233 259 /* This flag is already set if we authenticated via SASL, so now 234 we can resume the session in the new stream. */ 235 if( jd->flags & JFLAG_AUTHENTICATED ) 260 we can resume the session in the new stream, if we don't have 261 to bind/initialize the session. */ 262 if( jd->flags & JFLAG_AUTHENTICATED && ( jd->flags & ( JFLAG_WAIT_BIND | JFLAG_WAIT_SESSION ) ) == 0 ) 236 263 { 237 264 if( !jabber_get_roster( gc ) )
Note: See TracChangeset
for help on using the changeset viewer.