Mercurial > pidgin
comparison src/protocols/msn/msn.c @ 6701:b7e113a59b51
[gaim-migrate @ 7227]
Updated to MSN Protocol 9.
committer: Tailor Script <tailor@pidgin.im>
author | Christian Hammond <chipx86@chipx86.com> |
---|---|
date | Tue, 02 Sep 2003 04:32:16 +0000 |
parents | 0c5637b5462e |
children | 302ee2792e91 |
comparison
equal
deleted
inserted
replaced
6700:57161e3abbb5 | 6701:b7e113a59b51 |
---|---|
2 * @file msn.c The MSN protocol plugin | 2 * @file msn.c The MSN protocol plugin |
3 * | 3 * |
4 * gaim | 4 * gaim |
5 * | 5 * |
6 * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org> | 6 * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org> |
7 * | 7 * |
8 * This program is free software; you can redistribute it and/or modify | 8 * This program is free software; you can redistribute it and/or modify |
9 * it under the terms of the GNU General Public License as published by | 9 * it under the terms of the GNU General Public License as published by |
10 * the Free Software Foundation; either version 2 of the License, or | 10 * the Free Software Foundation; either version 2 of the License, or |
11 * (at your option) any later version. | 11 * (at your option) any later version. |
12 * | 12 * |
49 MsnSession *session = gc->proto_data; | 49 MsnSession *session = gc->proto_data; |
50 GaimAccount *account = gaim_connection_get_account(gc); | 50 GaimAccount *account = gaim_connection_get_account(gc); |
51 char outparams[MSN_BUF_LEN]; | 51 char outparams[MSN_BUF_LEN]; |
52 char *alias; | 52 char *alias; |
53 | 53 |
54 if (entry == NULL || *entry == '\0') | 54 if (entry == NULL || *entry == '\0') |
55 alias = g_strdup(""); | 55 alias = g_strdup(""); |
56 else | 56 else |
57 alias = g_strdup(entry); | 57 alias = g_strdup(entry); |
58 | 58 |
59 if (strlen(alias) >= BUDDY_ALIAS_MAXLEN) { | 59 if (strlen(alias) >= BUDDY_ALIAS_MAXLEN) { |
692 { | 692 { |
693 MsnSession *session = gc->proto_data; | 693 MsnSession *session = gc->proto_data; |
694 char buf[MSN_BUF_LEN]; | 694 char buf[MSN_BUF_LEN]; |
695 | 695 |
696 if (!strchr(who, '@')) { | 696 if (!strchr(who, '@')) { |
697 g_snprintf(buf, sizeof(buf), | 697 g_snprintf(buf, sizeof(buf), |
698 _("An MSN screenname must be in the form \"user@server.com\". " | 698 _("An MSN screenname must be in the form \"user@server.com\". " |
699 "Perhaps you meant %s@hotmail.com. No changes were made " | 699 "Perhaps you meant %s@hotmail.com. No changes were made " |
700 "to your allow list."), who); | 700 "to your allow list."), who); |
701 | 701 |
702 gaim_notify_error(gc, NULL, _("Invalid MSN screenname"), buf); | 702 gaim_notify_error(gc, NULL, _("Invalid MSN screenname"), buf); |
732 { | 732 { |
733 MsnSession *session = gc->proto_data; | 733 MsnSession *session = gc->proto_data; |
734 char buf[MSN_BUF_LEN]; | 734 char buf[MSN_BUF_LEN]; |
735 | 735 |
736 if (!strchr(who, '@')) { | 736 if (!strchr(who, '@')) { |
737 g_snprintf(buf, sizeof(buf), | 737 g_snprintf(buf, sizeof(buf), |
738 _("An MSN screenname must be in the form \"user@server.com\". " | 738 _("An MSN screenname must be in the form \"user@server.com\". " |
739 "Perhaps you meant %s@hotmail.com. No changes were made " | 739 "Perhaps you meant %s@hotmail.com. No changes were made " |
740 "to your block list."), who); | 740 "to your block list."), who); |
741 | 741 |
742 gaim_notify_error(gc, NULL, _("Invalid MSN screenname"), buf); | 742 gaim_notify_error(gc, NULL, _("Invalid MSN screenname"), buf); |
1293 } | 1293 } |
1294 | 1294 |
1295 static void | 1295 static void |
1296 msn_get_info(GaimConnection *gc, const char *name) | 1296 msn_get_info(GaimConnection *gc, const char *name) |
1297 { | 1297 { |
1298 /* MsnSession *session = (MsnSession *)gc->proto_data; */ | |
1299 char url[256]; | 1298 char url[256]; |
1300 g_snprintf(url, sizeof url, "%s%s", PROFILE_URL, name); | 1299 g_snprintf(url, sizeof url, "%s%s", PROFILE_URL, name); |
1301 grab_url(url, FALSE, msn_got_info, NULL,"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)",1); | 1300 grab_url(url, FALSE, msn_got_info, NULL,"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)",1); |
1302 } | 1301 } |
1303 | 1302 |