| 124 idata->recblocks = 0; |
124 idata->recblocks = 0; |
| 125 idata->totalblocks = 1; |
125 idata->totalblocks = 1; |
| 126 |
126 |
| 127 /* First, let's check to see if we have anyone on our buddylist */ |
127 /* First, let's check to see if we have anyone on our buddylist */ |
| 128 if (!grp) { |
128 if (!grp) { |
| 129 return; |
129 return TRUE; |
| 130 } |
130 } |
| 131 |
131 |
| 132 /* Send the first part of our request */ |
132 /* Send the first part of our request */ |
| 133 write(idata->fd, "ISON", 4); |
133 write(idata->fd, "ISON", 4); |
| 134 |
134 |
| 157 } |
157 } |
| 158 |
158 |
| 159 grp = g_slist_next(grp); |
159 grp = g_slist_next(grp); |
| 160 } |
160 } |
| 161 write(idata->fd, "\n", 1); |
161 write(idata->fd, "\n", 1); |
| |
162 return TRUE; |
| 162 } |
163 } |
| 163 |
164 |
| 164 |
165 |
| 165 static int irc_send_im(struct gaim_connection *gc, char *who, char *message, int away) |
166 static int irc_send_im(struct gaim_connection *gc, char *who, char *message, int away) |
| 166 { |
167 { |
| 1824 write(idata->fd, buf, strlen(buf)); |
1825 write(idata->fd, buf, strlen(buf)); |
| 1825 |
1826 |
| 1826 g_free(buf); |
1827 g_free(buf); |
| 1827 |
1828 |
| 1828 if (idata->timer) |
1829 if (idata->timer) |
| 1829 gtk_timeout_remove(idata->timer); |
1830 g_source_remove(idata->timer); |
| 1830 |
1831 |
| 1831 while (chats) { |
1832 while (chats) { |
| 1832 cc = (struct irc_channel *)chats->data; |
1833 cc = (struct irc_channel *)chats->data; |
| 1833 g_free(cc->name); |
1834 g_free(cc->name); |
| 1834 chats = g_list_remove(chats, cc); |
1835 chats = g_list_remove(chats, cc); |
| 1903 |
1904 |
| 1904 if (bud_list_cache_exists(gc)) |
1905 if (bud_list_cache_exists(gc)) |
| 1905 do_import(NULL, gc); |
1906 do_import(NULL, gc); |
| 1906 |
1907 |
| 1907 /* we don't call this now because otherwise some IRC servers might not like us */ |
1908 /* we don't call this now because otherwise some IRC servers might not like us */ |
| 1908 idata->timer = gtk_timeout_add(20000, (GtkFunction) irc_request_buddy_update, gc); |
1909 idata->timer = g_timeout_add(20000, irc_request_buddy_update, gc); |
| 1909 } |
1910 } |
| 1910 |
1911 |
| 1911 static void irc_login(struct aim_user *user) |
1912 static void irc_login(struct aim_user *user) |
| 1912 { |
1913 { |
| 1913 char buf[4096]; |
1914 char buf[4096]; |