Update of /cvsroot/gaim/gaim/src/protocols/yahoo
In directory usw-pr-cvs1:/tmp/cvs-serv27484
Modified Files:
yay.c
Log Message:
hopefully this should fix a segfault
Index: yay.c
===================================================================
RCS file: /cvsroot/gaim/gaim/src/protocols/yahoo/yay.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- yay.c 2001/10/14 11:36:36 1.18
+++ yay.c 2001/10/15 15:48:25 1.19
@@ -294,7 +294,12 @@
static void yahoo_notify(struct yahoo_session *sess, int socket, int type, int cont) {
struct gaim_connection *gc = sess->user_data;
- struct yahoo_data *yd = gc->proto_data;
+ struct yahoo_data *yd;
+
+ if (!g_slist_find(connections, gc))
+ return;
+
+ yd = gc->proto_data;
if (cont) {
struct conn *c = g_new0(struct conn, 1);
@@ -319,6 +324,13 @@
static void yahoo_got_connected(gpointer data, gint source, GaimInputCondition cond) {
struct connect *con = data;
+ struct gaim_connection *gc = con->sess->user_data;
+
+ if (!g_slist_find(connections, gc)) {
+ close(source);
+ g_free(con);
+ return;
+ }
debug_printf("got connected (possibly)\n");
yahoo_connected(con->sess, con->data, source);
|