Fixed base 64 encoding/decoding.

git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@1976 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
Matt Tucker 2003-06-21 19:40:32 +00:00 committed by mtucker
parent 7cc11fb96e
commit fc70c90e67
1 changed files with 3 additions and 3 deletions

View File

@ -285,7 +285,7 @@ public class StringUtils {
public static String encodeBase64(String data) {
byte [] bytes = null;
try {
bytes = data.getBytes("UTF8");
bytes = data.getBytes("ISO-8859-1");
}
catch (UnsupportedEncodingException uee) {
uee.printStackTrace();
@ -343,8 +343,8 @@ public class StringUtils {
public static byte[] decodeBase64(String data) {
byte [] bytes = null;
try {
bytes = data.getBytes("UTF8");
return decodeBase64(bytes).getBytes("UTF8");
bytes = data.getBytes("ISO-8859-1");
return decodeBase64(bytes).getBytes("ISO-8859-1");
}
catch (UnsupportedEncodingException uee) {
uee.printStackTrace();