Mercurial > pidgin.yaz
diff src/protocols/msn/nexus.c @ 9193:502707ca1836
[gaim-migrate @ 9988]
Patch by Felipe Contreras to add MSN file transfer and buddy icons. Please
test and report any bugs!
committer: Tailor Script <tailor@pidgin.im>
author | Christian Hammond <chipx86@chipx86.com> |
---|---|
date | Sun, 06 Jun 2004 02:39:08 +0000 |
parents | 577c76e1442d |
children | ab6636c5a136 |
line wrap: on
line diff
--- a/src/protocols/msn/nexus.c Sun Jun 06 02:16:08 2004 +0000 +++ b/src/protocols/msn/nexus.c Sun Jun 06 02:39:08 2004 +0000 @@ -65,7 +65,6 @@ { MsnNexus *nexus; MsnSession *session; - GaimConnection *gc; char *username, *password; char *request_str; char *buffer = NULL; @@ -77,9 +76,6 @@ session = nexus->session; g_return_if_fail(session != NULL); - gc = gaim_account_get_connection(session->account); - g_return_if_fail(gc != NULL); - username = g_strdup(gaim_url_encode(gaim_account_get_username(session->account))); @@ -118,7 +114,6 @@ if ((s = gaim_ssl_write(gsc, request_str, strlen(request_str))) <= 0) { g_free(request_str); - gaim_connection_error(gc, _("Unable to write to MSN Nexus server.")); return; } @@ -126,10 +121,7 @@ g_free(request_str); if ((s = msn_ssl_read(gsc, &buffer)) <= 0) - { - gaim_connection_error(gc, _("Unable to write to MSN Nexus server.")); return; - } gaim_ssl_close(gsc); @@ -143,14 +135,10 @@ location = strstr(buffer, "Location: "); if (location == NULL) { - gaim_connection_error(gc, - _("MSN Nexus server returned invalid redirect information.")); - g_free(buffer); return; } - location = strchr(location, ' ') + 1; if ((c = strchr(location, '\r')) != NULL) @@ -209,7 +197,6 @@ } else if (strstr(buffer, "HTTP/1.1 200 OK")) { - MsnCmdProc *cmdproc; char *base, *c; char *login_params; @@ -230,18 +217,9 @@ } #endif - cmdproc = session->notification_conn->cmdproc; base = strstr(buffer, "Authentication-Info: "); - if (base == NULL) - { - gaim_debug(GAIM_DEBUG_ERROR, "msn", - "Authentication information was not found. This did " - "not just happen, but if it did, you're screwed. " - "Report this.\n"); - - return; - } + g_return_if_fail(base != NULL); base = strstr(base, "from-PP='"); base += strlen("from-PP='"); @@ -249,7 +227,7 @@ login_params = g_strndup(base, c - base); - msn_cmdproc_send(cmdproc, "USR", "TWN S %s", login_params); + msn_got_login_params(session, login_params); g_free(login_params);