aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/yahoo/libyahoo2.c
diff options
context:
space:
mode:
authorulim <a.sporto+bee@gmail.com>2008-08-04 16:45:24 +0200
committerulim <a.sporto+bee@gmail.com>2008-08-04 16:45:24 +0200
commit8661caad555f4306cf36ee37979a7637b05d5cd4 (patch)
tree7e4a7c3d6a700610dd31d109508b07caa3253902 /protocols/yahoo/libyahoo2.c
parent4ac647dbcef152bebde7209f7c9cbbf8a5e0fc37 (diff)
parent718e05f842c1af043eb4efded8b0afe429377f70 (diff)
merged in upstream r410.
Only conflict was the correction of jabber normalization which I had already done.
Diffstat (limited to 'protocols/yahoo/libyahoo2.c')
-rw-r--r--protocols/yahoo/libyahoo2.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/protocols/yahoo/libyahoo2.c b/protocols/yahoo/libyahoo2.c
index 80d88a85..a61955c4 100644
--- a/protocols/yahoo/libyahoo2.c
+++ b/protocols/yahoo/libyahoo2.c
@@ -68,8 +68,6 @@ char *strchr (), *strrchr ();
#ifdef __MINGW32__
# include <winsock2.h>
-# define write(a,b,c) send(a,b,c,0)
-# define read(a,b,c) recv(a,b,c,0)
#endif
#include <stdlib.h>
@@ -380,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;
@@ -391,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)
{
@@ -796,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;
@@ -3165,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;
@@ -3841,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)