powered by Jive Software

Personal Message of MSN should be unescaped according to html before it is sent to client

Personal Message of MSN should be unescaped according to html before it is sent to client.

In detail:
public MSNBuddy(TransportBuddyManager manager, MsnContact msnContact) { super(manager, msnContact.getEmail().toString(), msnContact.getFriendlyName(), null); ArrayList groups = new ArrayList(); for (MsnGroup group : msnContact.getBelongGroups()) { groups.add(group.getGroupName()); } this.setGroups(groups); this.msnContact = msnContact; this.setPresenceAndStatus(((MSNTransport)getManager().getSession().getTransport()).convertMSNStatusToXMPP(msnContact.getStatus()), msnContact.getPersonalMessage()); }

see the last line, msnContact.getPersonalMessage() should be unescaped according to html rules.

Otherwise the following bug will occur:

if a person’s personal message looks like ^ ^, msnContact.getPersonalMessage() returns & # x 5 E ; & # x 5 E ;, and when it sends to client, the xml escapes it, that is, it changes to & a m p ; # x 5 E ; & a m p ; # x 5 E ;. So client displays it as & # x 5 E ; & # x 5 E ;.

Thanks,
Nako Ruru