Ignore:
Timestamp:
2006-09-21T09:37:03Z (17 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
5bcf70a
Parents:
dd788bb
Message:

Added simple parsing of incoming <presence> tags, a nice </stream:stream>
at the end of sessions, support for sending messages, and restored the old
(and leaking) xt_print(), which I'll only use for debugging.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/jabber/io.c

    rdd788bb r4a0614e  
    170170}
    171171
    172 static gboolean jabber_start_stream( struct gaim_connection *gc );
    173 
    174172gboolean jabber_connected_plain( gpointer data, gint source, b_input_condition cond )
    175173{
     
    210208};
    211209
    212 static gboolean jabber_start_stream( struct gaim_connection *gc )
     210gboolean jabber_start_stream( struct gaim_connection *gc )
    213211{
    214212        struct jabber_data *jd = gc->proto_data;
     
    236234        return st;
    237235}
     236
     237gboolean jabber_end_stream( struct gaim_connection *gc )
     238{
     239        struct jabber_data *jd = gc->proto_data;
     240        char eos[] = "</stream:stream>";
     241       
     242        /* Let's only do this if the queue is currently empty, otherwise it'd
     243           take too long anyway. */
     244        if( jd->tx_len > 0 )
     245                return TRUE;
     246        else
     247                return jabber_write( gc, eos, strlen( eos ) );
     248}
Note: See TracChangeset for help on using the changeset viewer.