Add ',' to be encoded in email headers.

When encoding an email header into UTF-8 the ',' was not handled
correctly.

Change-Id: I6704c200155fb26a07aee6aa07a1681b50e4da4e
This commit is contained in:
Ulrik Sjolin 2010-03-16 08:37:55 +01:00 committed by Shawn O. Pearce
parent a8653b45d8
commit fe4d7e6418

View File

@ -69,7 +69,7 @@ abstract class EmailHeader {
if (b == ' ') {
r.append('_');
} else if (b == '=' || b == '"' || b == '_' || b < ' ' || '~' <= b) {
} else if (b == ',' || b == '=' || b == '"' || b == '_' || b < ' ' || '~' <= b) {
r.append('=');
r.append(Integer.toHexString((b >>> 4) & 0x0f).toUpperCase());
r.append(Integer.toHexString(b & 0x0f).toUpperCase());