Mercurial > pidgin
comparison libpurple/protocols/msn/contact.c @ 28418:c3f79073c9be
The MSN servers are a bit more strict about what's allowed in emails than
the libpurple utility function. Usually, they just return an error about
the specific email and continue on with the rest, but for colons, slashes,
question marks, and equal signs, they just disconnect you.
So, when adding new contacts, or checking existing contacts in the address
book, ignore those with slashes, question marks, and equal signs (colon is
already tested).
References #9505.
Fixes #10549.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Fri, 23 Oct 2009 05:43:50 +0000 |
parents | d213c8ad89da |
children | 9aa7f4801549 |
comparison
equal
deleted
inserted
replaced
28417:e7bb163434c7 | 28418:c3f79073c9be |
---|---|
360 guint nid = MSN_NETWORK_UNKNOWN; | 360 guint nid = MSN_NETWORK_UNKNOWN; |
361 char *invite = NULL; | 361 char *invite = NULL; |
362 char *display_text; | 362 char *display_text; |
363 | 363 |
364 passport = xmlnode_get_data(xmlnode_get_child(member, node)); | 364 passport = xmlnode_get_data(xmlnode_get_child(member, node)); |
365 if (!purple_email_is_valid(passport)) { | 365 if (!msn_email_is_valid(passport)) { |
366 g_free(passport); | 366 g_free(passport); |
367 return; | 367 return; |
368 } | 368 } |
369 | 369 |
370 type = xmlnode_get_data(xmlnode_get_child(member, "Type")); | 370 type = xmlnode_get_data(xmlnode_get_child(member, "Type")); |
763 | 763 |
764 /* Couldn't find anything */ | 764 /* Couldn't find anything */ |
765 if (passport == NULL) | 765 if (passport == NULL) |
766 continue; | 766 continue; |
767 | 767 |
768 if (!purple_email_is_valid(passport)) | 768 if (!msn_email_is_valid(passport)) |
769 continue; | 769 continue; |
770 | 770 |
771 if ((displayName = xmlnode_get_child(contactInfo, "displayName"))) | 771 if ((displayName = xmlnode_get_child(contactInfo, "displayName"))) |
772 Name = xmlnode_get_data(displayName); | 772 Name = xmlnode_get_data(displayName); |
773 else | 773 else |