libpurple/protocols/msn/error.c

Sat, 30 Aug 2008 20:21:04 +0000

author
Elliott Sales de Andrade <qulogic@pidgin.im>
date
Sat, 30 Aug 2008 20:21:04 +0000
changeset 24219
11627ee97ad5
parent 23441
fd45c23a3eb2
child 24223
eaa5d0b6ef07
permissions
-rw-r--r--

Add MSN error code 927 for suspended passports, and a little bit of
indent cleanup. Note: Add translation after string-freeze.

References #6723.

5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
1 /**
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
2 * @file error.c Error functions
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
3 *
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15753
diff changeset
4 * purple
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
5 *
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15753
diff changeset
6 * Purple is the legal property of its developers, whose names are too numerous
9198
e8eb6d5eb9eb [gaim-migrate @ 9993]
Christian Hammond <chipx86@chipx86.com>
parents: 8662
diff changeset
7 * to list here. Please refer to the COPYRIGHT file distributed with this
e8eb6d5eb9eb [gaim-migrate @ 9993]
Christian Hammond <chipx86@chipx86.com>
parents: 8662
diff changeset
8 * source distribution.
6701
7e2db9273748 [gaim-migrate @ 7227]
Christian Hammond <chipx86@chipx86.com>
parents: 5436
diff changeset
9 *
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
10 * This program is free software; you can redistribute it and/or modify
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
11 * it under the terms of the GNU General Public License as published by
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
12 * the Free Software Foundation; either version 2 of the License, or
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
13 * (at your option) any later version.
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
14 *
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
15 * This program is distributed in the hope that it will be useful,
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
18 * GNU General Public License for more details.
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
19 *
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
20 * You should have received a copy of the GNU General Public License
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
21 * along with this program; if not, write to the Free Software
19859
71d37b57eff2 The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 15884
diff changeset
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
23 */
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
24 #include "msn.h"
5436
a0e0bacaa196 [gaim-migrate @ 5818]
Christian Hammond <chipx86@chipx86.com>
parents: 5309
diff changeset
25 #include "error.h"
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
26
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
27 const char *
15740
1448fbe9b0d5 Remove a few unneeded strings, per evans's recommendation
Sean Egan <seanegan@pidgin.im>
parents: 15444
diff changeset
28 msn_error_get_text(unsigned int type, gboolean *debug)
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
29 {
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
30 static char msg[MSN_BUF_LEN];
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
31 *debug = FALSE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
32
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
33 switch (type) {
8569
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
34 case 0:
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
35 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
36 _("Unable to parse message"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
37 *debug = TRUE;
15740
1448fbe9b0d5 Remove a few unneeded strings, per evans's recommendation
Sean Egan <seanegan@pidgin.im>
parents: 15444
diff changeset
38 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
39 case 200:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
40 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
41 _("Syntax Error (probably a client bug)"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
42 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
43 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
44 case 201:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
45 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
46 _("Invalid email address"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
47 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
48 case 205:
8569
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
49 g_snprintf(msg, sizeof(msg), _("User does not exist"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
50 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
51 case 206:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
52 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
53 _("Fully qualified domain name missing"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
54 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
55 case 207:
15062
78e3c1c8c4f4 [gaim-migrate @ 17779]
Richard Laager <rlaager@pidgin.im>
parents: 14254
diff changeset
56 g_snprintf(msg, sizeof(msg), _("Already logged in"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
57 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
58 case 208:
22942
2bf494f8e2a4 Change the string "screen name" to "username" everywhere. I think most
Mark Doliner <markdoliner@pidgin.im>
parents: 19859
diff changeset
59 g_snprintf(msg, sizeof(msg), _("Invalid username"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
60 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
61 case 209:
15062
78e3c1c8c4f4 [gaim-migrate @ 17779]
Richard Laager <rlaager@pidgin.im>
parents: 14254
diff changeset
62 g_snprintf(msg, sizeof(msg), _("Invalid friendly name"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
63 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
64 case 210:
15062
78e3c1c8c4f4 [gaim-migrate @ 17779]
Richard Laager <rlaager@pidgin.im>
parents: 14254
diff changeset
65 g_snprintf(msg, sizeof(msg), _("List full"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
66 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
67 case 215:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
68 g_snprintf(msg, sizeof(msg), _("Already there"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
69 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
70 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
71 case 216:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
72 g_snprintf(msg, sizeof(msg), _("Not on list"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
73 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
74 case 217:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
75 g_snprintf(msg, sizeof(msg), _("User is offline"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
76 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
77 case 218:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
78 g_snprintf(msg, sizeof(msg), _("Already in the mode"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
79 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
80 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
81 case 219:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
82 g_snprintf(msg, sizeof(msg), _("Already in opposite list"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
83 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
84 break;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
85 case 223:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
86 g_snprintf(msg, sizeof(msg), _("Too many groups"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
87 break;
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
88 case 224:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
89 g_snprintf(msg, sizeof(msg), _("Invalid group"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
90 break;
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
91 case 225:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
92 g_snprintf(msg, sizeof(msg), _("User not in group"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
93 break;
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
94 case 229:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
95 g_snprintf(msg, sizeof(msg), _("Group name too long"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
96 break;
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
97 case 230:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
98 g_snprintf(msg, sizeof(msg), _("Cannot remove group zero"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
99 *debug = TRUE;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
100 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
101 case 231:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
102 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
103 _("Tried to add a user to a group "
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
104 "that doesn't exist"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
105 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
106 case 280:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
107 g_snprintf(msg, sizeof(msg), _("Switchboard failed"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
108 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
109 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
110 case 281:
15062
78e3c1c8c4f4 [gaim-migrate @ 17779]
Richard Laager <rlaager@pidgin.im>
parents: 14254
diff changeset
111 g_snprintf(msg, sizeof(msg), _("Notify transfer failed"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
112 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
113 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
114
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
115 case 300:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
116 g_snprintf(msg, sizeof(msg), _("Required fields missing"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
117 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
118 break;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
119 case 301:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
120 g_snprintf(msg, sizeof(msg), _("Too many hits to a FND"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
121 *debug = TRUE;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
122 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
123 case 302:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
124 g_snprintf(msg, sizeof(msg), _("Not logged in"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
125 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
126
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
127 case 500:
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
128 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
129 _("Service temporarily unavailable"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
130 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
131 case 501:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
132 g_snprintf(msg, sizeof(msg), _("Database server error"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
133 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
134 break;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
135 case 502:
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
136 g_snprintf(msg, sizeof(msg), _("Command disabled"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
137 *debug = TRUE;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
138 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
139 case 510:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
140 g_snprintf(msg, sizeof(msg), _("File operation error"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
141 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
142 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
143 case 520:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
144 g_snprintf(msg, sizeof(msg), _("Memory allocation error"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
145 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
146 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
147 case 540:
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
148 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
149 _("Wrong CHL value sent to server"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
150 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
151 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
152
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
153 case 600:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
154 g_snprintf(msg, sizeof(msg), _("Server busy"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
155 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
156 case 601:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
157 g_snprintf(msg, sizeof(msg), _("Server unavailable"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
158 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
159 case 602:
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
160 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
161 _("Peer notification server down"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
162 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
163 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
164 case 603:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
165 g_snprintf(msg, sizeof(msg), _("Database connect error"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
166 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
167 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
168 case 604:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
169 g_snprintf(msg, sizeof(msg),
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
170 _("Server is going down (abandon ship)"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
171 break;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
172 case 605:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
173 g_snprintf(msg, sizeof(msg), _("Server unavailable"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
174 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
175
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
176 case 707:
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
177 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
178 _("Error creating connection"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
179 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
180 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
181 case 710:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
182 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
183 _("CVR parameters are either unknown "
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
184 "or not allowed"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
185 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
186 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
187 case 711:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
188 g_snprintf(msg, sizeof(msg), _("Unable to write"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
189 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
190 case 712:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
191 g_snprintf(msg, sizeof(msg), _("Session overload"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
192 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
193 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
194 case 713:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
195 g_snprintf(msg, sizeof(msg), _("User is too active"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
196 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
197 case 714:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
198 g_snprintf(msg, sizeof(msg), _("Too many sessions"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
199 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
200 case 715:
8569
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
201 g_snprintf(msg, sizeof(msg), _("Passport not verified"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
202 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
203 case 717:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
204 g_snprintf(msg, sizeof(msg), _("Bad friend file"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
205 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
206 break;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
207 case 731:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
208 g_snprintf(msg, sizeof(msg), _("Not expected"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
209 *debug = TRUE;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
210 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
211
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
212 case 800:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
213 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
214 _("Friendly name changes too rapidly"));
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
215 break;
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
216
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
217 case 910:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
218 case 912:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
219 case 918:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
220 case 919:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
221 case 921:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
222 case 922:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
223 g_snprintf(msg, sizeof(msg), _("Server too busy"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
224 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
225 case 911:
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
226 case 917:
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
227 g_snprintf(msg, sizeof(msg), _("Authentication failed"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
228 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
229 case 913:
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
230 g_snprintf(msg, sizeof(msg), _("Not allowed when offline"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
231 break;
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
232 case 914:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
233 case 915:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
234 case 916:
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
235 g_snprintf(msg, sizeof(msg), _("Server unavailable"));
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
236 break;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
237 case 920:
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
238 g_snprintf(msg, sizeof(msg), _("Not accepting new users"));
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
239 break;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
240 case 923:
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
241 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
242 _("Kids Passport without parental consent"));
6887
b41f14f8ad16 [gaim-migrate @ 7433]
Christian Hammond <chipx86@chipx86.com>
parents: 6701
diff changeset
243 break;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
244 case 924:
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
245 g_snprintf(msg, sizeof(msg),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
246 _("Passport account not yet verified"));
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
247 break;
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
248 case 927:
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
249 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
250 ("Passport account suspended"));
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
251 break;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
252 case 928:
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
253 g_snprintf(msg, sizeof(msg), _("Bad ticket"));
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
254 *debug = TRUE;
8255
187d01c945ea [gaim-migrate @ 8978]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 7086
diff changeset
255 break;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
256
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
257 default:
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
258 g_snprintf(msg, sizeof(msg),
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
259 _("Unknown Error Code %d"), type);
15753
8a0b761dfd7b I think this is what Sean intended
Mark Doliner <markdoliner@pidgin.im>
parents: 15740
diff changeset
260 *debug = TRUE;
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
261 break;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
262 }
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
263
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
264 return msg;
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
265 }
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
266
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
267 void
5436
a0e0bacaa196 [gaim-migrate @ 5818]
Christian Hammond <chipx86@chipx86.com>
parents: 5309
diff changeset
268 msn_error_handle(MsnSession *session, unsigned int type)
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
269 {
8569
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
270 char buf[MSN_BUF_LEN];
15740
1448fbe9b0d5 Remove a few unneeded strings, per evans's recommendation
Sean Egan <seanegan@pidgin.im>
parents: 15444
diff changeset
271 gboolean debug;
23441
fd45c23a3eb2 Delete trailing whitespace
Mark Doliner <markdoliner@pidgin.im>
parents: 23325
diff changeset
272
8569
8dcc51f809e6 [gaim-migrate @ 9317]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 8475
diff changeset
273 g_snprintf(buf, sizeof(buf), _("MSN Error: %s\n"),
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
274 msn_error_get_text(type, &debug));
15740
1448fbe9b0d5 Remove a few unneeded strings, per evans's recommendation
Sean Egan <seanegan@pidgin.im>
parents: 15444
diff changeset
275 if (debug)
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15753
diff changeset
276 purple_debug_warning("msn", "error %d: %s\n", type, buf);
15740
1448fbe9b0d5 Remove a few unneeded strings, per evans's recommendation
Sean Egan <seanegan@pidgin.im>
parents: 15444
diff changeset
277 else
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15753
diff changeset
278 purple_notify_error(session->account->gc, NULL, buf, NULL);
5309
3178acad1449 [gaim-migrate @ 5681]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
279 }
24219
11627ee97ad5 Add MSN error code 927 for suspended passports, and a little bit of
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 23441
diff changeset
280

mercurial