1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2025-09-13 11:09:39 +02:00

Use Locale.US when doing String operations

on machine readable output. The default locale may not provide the
wanted mapping. See also
http://developer.android.com/reference/java/util/Locale.html#default_locale

SMACK-467
This commit is contained in:
Florian Schmaus 2014-04-03 22:50:13 +02:00
parent 94adaf8e50
commit d8a5610d7b
24 changed files with 67 additions and 39 deletions

View file

@ -21,6 +21,7 @@ import java.io.IOException;
import java.io.PipedReader;
import java.io.PipedWriter;
import java.io.Writer;
import java.util.Locale;
import java.util.logging.Level;
import java.util.logging.Logger;
@ -247,7 +248,7 @@ public class BOSHConnection extends XMPPConnection {
throw new AlreadyLoggedInException();
}
// Do partial version of nameprep on the username.
username = username.toLowerCase().trim();
username = username.toLowerCase(Locale.US).trim();
String response;
if (saslAuthentication.hasNonAnonymousAuthentication()) {