Mercurial > pidgin.yaz
comparison libpurple/protocols/irc/irc.c @ 32771:a78523019e7a
IRC: Move the "inpa" input watcher into protocol_data.
| author | andrew.victor@mxit.com |
|---|---|
| date | Tue, 18 Oct 2011 21:11:40 +0000 |
| parents | 50cd80d3554e |
| children | 4a34689eeb33 |
comparison
equal
deleted
inserted
replaced
| 32770:a5f50581b7c0 | 32771:a78523019e7a |
|---|---|
| 498 } | 498 } |
| 499 | 499 |
| 500 irc->fd = source; | 500 irc->fd = source; |
| 501 | 501 |
| 502 if (do_login(gc)) { | 502 if (do_login(gc)) { |
| 503 gc->inpa = purple_input_add(irc->fd, PURPLE_INPUT_READ, irc_input_cb, gc); | 503 irc->inpa = purple_input_add(irc->fd, PURPLE_INPUT_READ, irc_input_cb, gc); |
| 504 } | 504 } |
| 505 } | 505 } |
| 506 | 506 |
| 507 static void | 507 static void |
| 508 irc_ssl_connect_failure(PurpleSslConnection *gsc, PurpleSslErrorType error, | 508 irc_ssl_connect_failure(PurpleSslConnection *gsc, PurpleSslErrorType error, |
| 524 return; | 524 return; |
| 525 | 525 |
| 526 if (irc->gsc || (irc->fd >= 0)) | 526 if (irc->gsc || (irc->fd >= 0)) |
| 527 irc_cmd_quit(irc, "quit", NULL, NULL); | 527 irc_cmd_quit(irc, "quit", NULL, NULL); |
| 528 | 528 |
| 529 if (gc->inpa) | 529 if (irc->inpa) { |
| 530 purple_input_remove(gc->inpa); | 530 purple_input_remove(irc->inpa); |
| 531 irc->inpa = 0; | |
| 532 } | |
| 531 | 533 |
| 532 g_free(irc->inbuf); | 534 g_free(irc->inbuf); |
| 533 if (irc->gsc) { | 535 if (irc->gsc) { |
| 534 purple_ssl_close(irc->gsc); | 536 purple_ssl_close(irc->gsc); |
| 535 } else if (irc->fd >= 0) { | 537 } else if (irc->fd >= 0) { |
