comparison src/protocols/toc/toc.c @ 5681:46d7ad0dfa26

[gaim-migrate @ 6100] Rewrote the proxy code. It should now work with the new prefs, and it has a namespace and API too! committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Tue, 03 Jun 2003 02:00:33 +0000
parents 0a0116686d51
children 43ea75092684
comparison
equal deleted inserted replaced
5680:71cc0d5376c2 5681:46d7ad0dfa26
190 g_snprintf(buf, sizeof buf, _("Looking up %s"), 190 g_snprintf(buf, sizeof buf, _("Looking up %s"),
191 gaim_account_get_string(account, "server", TOC_HOST)); 191 gaim_account_get_string(account, "server", TOC_HOST));
192 gaim_connection_update_progress(gc, buf, 1, TOC_CONNECT_STEPS); 192 gaim_connection_update_progress(gc, buf, 1, TOC_CONNECT_STEPS);
193 193
194 debug_printf("* Client connects to TOC\n"); 194 debug_printf("* Client connects to TOC\n");
195 if (proxy_connect(account, 195 if (gaim_proxy_connect(account,
196 gaim_account_get_string(account, "server", TOC_HOST), 196 gaim_account_get_string(account, "server", TOC_HOST),
197 gaim_account_get_int(account, "port", TOC_PORT), 197 gaim_account_get_int(account, "port", TOC_PORT),
198 toc_login_callback, gc) != 0 || !account->gc) { 198 toc_login_callback, gc) != 0 || !account->gc) {
199 g_snprintf(buf, sizeof(buf), "Connect to %s failed", 199 g_snprintf(buf, sizeof(buf), "Connect to %s failed",
200 gaim_account_get_string(account, "server", TOC_HOST)); 200 gaim_account_get_string(account, "server", TOC_HOST));
1681 gtk_widget_destroy(old_ft->window); 1681 gtk_widget_destroy(old_ft->window);
1682 1682
1683 g_snprintf(buf, sizeof(buf), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_SEND_UID); 1683 g_snprintf(buf, sizeof(buf), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_SEND_UID);
1684 sflap_send(ft->gc, buf, -1, TYPE_DATA); 1684 sflap_send(ft->gc, buf, -1, TYPE_DATA);
1685 1685
1686 if (proxy_connect(account, ft->ip, ft->port, toc_send_file_connect, ft) != 0) { 1686 if (gaim_proxy_connect(account, ft->ip, ft->port, toc_send_file_connect, ft) != 0) {
1687 gaim_notify_error(ft->gc, NULL, 1687 gaim_notify_error(ft->gc, NULL,
1688 _("Could not connect for transfer."), NULL); 1688 _("Could not connect for transfer."), NULL);
1689 g_free(ft->filename); 1689 g_free(ft->filename);
1690 g_free(ft->cookie); 1690 g_free(ft->cookie);
1691 g_free(ft->user); 1691 g_free(ft->user);
1893 gtk_widget_destroy(old_ft->window); 1893 gtk_widget_destroy(old_ft->window);
1894 1894
1895 g_snprintf(buf2, sizeof(buf2), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_GET_UID); 1895 g_snprintf(buf2, sizeof(buf2), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_GET_UID);
1896 sflap_send(ft->gc, buf2, -1, TYPE_DATA); 1896 sflap_send(ft->gc, buf2, -1, TYPE_DATA);
1897 1897
1898 if (proxy_connect(account, ft->ip, ft->port, toc_get_file_connect, ft) < 0) { 1898 if (gaim_proxy_connect(account, ft->ip, ft->port, toc_get_file_connect, ft) < 0) {
1899 gaim_notify_error(ft->gc, NULL, 1899 gaim_notify_error(ft->gc, NULL,
1900 _("Could not connect for transfer."), NULL); 1900 _("Could not connect for transfer."), NULL);
1901 fclose(ft->file); 1901 fclose(ft->file);
1902 g_free(ft->filename); 1902 g_free(ft->filename);
1903 g_free(ft->cookie); 1903 g_free(ft->cookie);