Mercurial > pidgin.yaz
comparison libfaim/conn.c @ 1593:ec31e23aadc7
[gaim-migrate @ 1603]
libfaim updates and a bug fix for bad password.
committer: Tailor Script <tailor@pidgin.im>
author | Eric Warmenhoven <eric@warmenhoven.org> |
---|---|
date | Fri, 16 Mar 2001 14:29:54 +0000 |
parents | 1e2cc8c8bf3c |
children | 3fe5799b7823 |
comparison
equal
deleted
inserted
replaced
1592:41cecde078c1 | 1593:ec31e23aadc7 |
---|---|
109 { | 109 { |
110 struct aim_conn_t *cur; | 110 struct aim_conn_t *cur; |
111 | 111 |
112 if (!deadconn || !*deadconn) | 112 if (!deadconn || !*deadconn) |
113 return; | 113 return; |
114 | |
115 aim_tx_cleanqueue(sess, *deadconn); | |
114 | 116 |
115 faim_mutex_lock(&sess->connlistlock); | 117 faim_mutex_lock(&sess->connlistlock); |
116 if (sess->connlist == NULL) | 118 if (sess->connlist == NULL) |
117 ; | 119 ; |
118 else if (sess->connlist->next == NULL) { | 120 else if (sess->connlist->next == NULL) { |
538 * | 540 * |
539 * XXX: we could probably stand to do a little courser locking here. | 541 * XXX: we could probably stand to do a little courser locking here. |
540 * | 542 * |
541 */ | 543 */ |
542 faim_export struct aim_conn_t *aim_select(struct aim_session_t *sess, | 544 faim_export struct aim_conn_t *aim_select(struct aim_session_t *sess, |
543 struct timeval *timeout, int *status) | 545 struct timeval *timeout, |
546 int *status) | |
544 { | 547 { |
545 struct aim_conn_t *cur; | 548 struct aim_conn_t *cur; |
546 fd_set fds, wfds; | 549 fd_set fds, wfds; |
547 int maxfd = 0; | 550 int maxfd = 0; |
548 int i, haveconnecting = 0; | 551 int i, haveconnecting = 0; |
566 *status = 2; | 569 *status = 2; |
567 faim_mutex_unlock(&sess->connlistlock); | 570 faim_mutex_unlock(&sess->connlistlock); |
568 return cur; | 571 return cur; |
569 } else if (cur->status & AIM_CONN_STATUS_INPROGRESS) { | 572 } else if (cur->status & AIM_CONN_STATUS_INPROGRESS) { |
570 FD_SET(cur->fd, &wfds); | 573 FD_SET(cur->fd, &wfds); |
574 | |
571 haveconnecting++; | 575 haveconnecting++; |
572 } | 576 } |
573 FD_SET(cur->fd, &fds); | 577 FD_SET(cur->fd, &fds); |
574 if (cur->fd > maxfd) | 578 if (cur->fd > maxfd) |
575 maxfd = cur->fd; | 579 maxfd = cur->fd; |