comparison src/oscar.c @ 516:ee4e18868584

[gaim-migrate @ 526] Make it obvious that it happens. committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Fri, 21 Jul 2000 18:08:00 +0000
parents b33ed0a7f49b
children dd4d415dbe52
comparison
equal deleted inserted replaced
515:b33ed0a7f49b 516:ee4e18868584
120 debug_print(_("connection error!\n")); 120 debug_print(_("connection error!\n"));
121 if (direct) { 121 if (direct) {
122 struct conversation *cnv = find_conversation(direct); 122 struct conversation *cnv = find_conversation(direct);
123 debug_print("connection error for directim\n"); 123 debug_print("connection error for directim\n");
124 if (cnv) { 124 if (cnv) {
125 cnv->is_direct = 0; 125 make_direct(cnv, FALSE, NULL, 0);
126 cnv->conn = NULL;
127 gdk_input_remove(cnv->watcher);
128 } 126 }
129 } 127 }
130 aim_conn_kill(gaim_sess, &conn); 128 aim_conn_kill(gaim_sess, &conn);
131 if (!aim_getconn_type(gaim_sess, AIM_CONN_TYPE_BOS)) { 129 if (!aim_getconn_type(gaim_sess, AIM_CONN_TYPE_BOS)) {
132 debug_print(_("major connection error\n")); 130 debug_print(_("major connection error\n"));
966 } 964 }
967 965
968 void oscar_do_directim(char *name) { 966 void oscar_do_directim(char *name) {
969 struct aim_conn_t *newconn = aim_directim_initiate(gaim_sess, gaim_conn, NULL, name); 967 struct aim_conn_t *newconn = aim_directim_initiate(gaim_sess, gaim_conn, NULL, name);
970 struct conversation *cnv = find_conversation(name); /* this will never be null because it just got set up */ 968 struct conversation *cnv = find_conversation(name); /* this will never be null because it just got set up */
971 cnv->is_direct = TRUE; 969 int watcher = gdk_input_add(newconn->fd, GDK_INPUT_READ | GDK_INPUT_EXCEPTION, oscar_callback, newconn);
972 cnv->conn = newconn; 970 make_direct(cnv, TRUE, newconn, watcher);
973 cnv->watcher = gdk_input_add(newconn->fd, GDK_INPUT_READ | GDK_INPUT_EXCEPTION, oscar_callback, newconn);
974 aim_conn_addhandler(gaim_sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMINITIATE, gaim_directim_initiate, 0); 971 aim_conn_addhandler(gaim_sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMINITIATE, gaim_directim_initiate, 0);
975 } 972 }