Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/msn/msn.c

    r5a5c926 r1053836  
    6464        GSList *l;
    6565       
    66         if( md )
    67         {
    68                 if( md->fd >= 0 )
    69                         closesocket( md->fd );
    70                
    71                 if( md->handler )
    72                 {
    73                         if( md->handler->rxq ) g_free( md->handler->rxq );
    74                         if( md->handler->cmd_text ) g_free( md->handler->cmd_text );
    75                         g_free( md->handler );
    76                 }
    77                
    78                 while( md->switchboards )
    79                         msn_sb_destroy( md->switchboards->data );
    80                
    81                 if( md->msgq )
    82                 {
    83                         struct msn_message *m;
    84                        
    85                         for( l = md->msgq; l; l = l->next )
    86                         {
    87                                 m = l->data;
    88                        
    89                                 serv_got_crap( gc, "Warning: Closing down MSN connection with unsent message to %s, you'll have to resend it.", m->who );
    90                                 g_free( m->who );
    91                                 g_free( m->text );
    92                                 g_free( m );
    93                         }
    94                         g_slist_free( md->msgq );
    95                 }
    96                
    97                 g_free( md );
     66        if( md->fd >= 0 )
     67                closesocket( md->fd );
     68       
     69        if( md->handler )
     70        {
     71                if( md->handler->rxq ) g_free( md->handler->rxq );
     72                if( md->handler->cmd_text ) g_free( md->handler->cmd_text );
     73                g_free( md->handler );
     74        }
     75       
     76        while( md->switchboards )
     77                msn_sb_destroy( md->switchboards->data );
     78       
     79        if( md->msgq )
     80        {
     81                struct msn_message *m;
     82               
     83                for( l = md->msgq; l; l = l->next )
     84                {
     85                        m = l->data;
     86               
     87                        serv_got_crap( gc, "Warning: Closing down MSN connection with unsent message to %s, you'll have to resend it.", m->who );
     88                        g_free( m->who );
     89                        g_free( m->text );
     90                        g_free( m );
     91                }
     92                g_slist_free( md->msgq );
    9893        }
    9994       
     
    105100                g_free( l->data );
    106101        g_slist_free( gc->deny );
     102       
     103        g_free( md );
    107104       
    108105        msn_connections = g_slist_remove( msn_connections, gc );
Note: See TracChangeset for help on using the changeset viewer.