diff options
| author | Jelmer Vernooij <jelmer@samba.org> | 2008-06-28 19:32:41 +0200 | 
|---|---|---|
| committer | Jelmer Vernooij <jelmer@samba.org> | 2008-06-28 19:32:41 +0200 | 
| commit | 178e2f8f71e5ebd4501f455c874f816b9ba19ade (patch) | |
| tree | 8185c7ed827ca1cea4fac1431e9d8a2eeff86fa3 /protocols/yahoo | |
| parent | 2e0f24d00b85c617400413bb2d179fd1028420c4 (diff) | |
| parent | e0f9170849e9c4aaa679f86703a60686d36607bb (diff) | |
Merge trunk.
Diffstat (limited to 'protocols/yahoo')
| -rw-r--r-- | protocols/yahoo/libyahoo2.c | 11 | ||||
| -rw-r--r-- | protocols/yahoo/yahoo.c | 9 | 
2 files changed, 5 insertions, 15 deletions
| diff --git a/protocols/yahoo/libyahoo2.c b/protocols/yahoo/libyahoo2.c index 4e33d0ab..a61955c4 100644 --- a/protocols/yahoo/libyahoo2.c +++ b/protocols/yahoo/libyahoo2.c @@ -378,7 +378,6 @@ static void del_from_list(struct yahoo_data *yd)  }  /* call repeatedly to get the next one */ -/*  static struct yahoo_input_data * find_input_by_id(int id)  {  	YList *l; @@ -389,7 +388,6 @@ static struct yahoo_input_data * find_input_by_id(int id)  	}  	return NULL;  } -*/  static struct yahoo_input_data * find_input_by_id_and_webcam_user(int id, const char * who)  { @@ -794,6 +792,7 @@ static int yahoo_send_data(int fd, void *data, int len)  void yahoo_close(int id)   {  	struct yahoo_data *yd = find_conn_by_id(id); +	  	if(!yd)  		return; @@ -3163,7 +3162,7 @@ int yahoo_write_ready(int id, int fd, void *data)  	struct data_queue *tx;  	LOG(("write callback: id=%d fd=%d data=%p", id, fd, data)); -	if(!yid || !yid->txqueues) +	if(!yid || !yid->txqueues || !find_conn_by_id(id))  		return -2;  	tx = yid->txqueues->data; @@ -3839,11 +3838,9 @@ void yahoo_logoff(int id)  		}  	} -	 -/*	do { +	do {  		yahoo_input_close(yid); -	} while((yid = find_input_by_id(id)));*/ -	 +	} while((yid = find_input_by_id(id)));  }  void yahoo_get_list(int id) diff --git a/protocols/yahoo/yahoo.c b/protocols/yahoo/yahoo.c index ab30df4d..197d76a1 100644 --- a/protocols/yahoo/yahoo.c +++ b/protocols/yahoo/yahoo.c @@ -162,10 +162,7 @@ static void byahoo_logout( struct im_connection *ic )  	}  	g_slist_free( yd->buddygroups ); -	if( yd->logged_in ) -		yahoo_logoff( yd->y2_id ); -	else -		yahoo_close( yd->y2_id ); +	yahoo_logoff( yd->y2_id );  	g_free( yd );  } @@ -453,10 +450,6 @@ gboolean byahoo_write_ready_callback( gpointer data, gint source, b_input_condit  {  	struct byahoo_write_ready_data *d = data; -	if( !byahoo_get_ic_by_id( d->id ) ) -		/* WTF doesn't libyahoo clean this up? */ -		return FALSE; -	  	yahoo_write_ready( d->id, d->fd, d->data );  	return FALSE; | 
