Fix Music import for Turkish locales.
For non-localized strings like the keywords in SQL statements, we shouldn't use locale-specific case transformations. (Cherry pick of 03f8f84c345e7c861a6de889d434b9d82cf04c8d.) Bug: 4284951 Change-Id: If5b7154f70a7db22837d071d1c57e929729b7d35
This commit is contained in:
@@ -39,6 +39,7 @@ import java.io.FileNotFoundException;
|
|||||||
import java.io.PrintStream;
|
import java.io.PrintStream;
|
||||||
import java.text.Collator;
|
import java.text.Collator;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
import java.util.Locale;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -1318,7 +1319,7 @@ public class DatabaseUtils {
|
|||||||
if (sql.length() < 3) {
|
if (sql.length() < 3) {
|
||||||
return STATEMENT_OTHER;
|
return STATEMENT_OTHER;
|
||||||
}
|
}
|
||||||
String prefixSql = sql.substring(0, 3).toUpperCase();
|
String prefixSql = sql.substring(0, 3).toUpperCase(Locale.US);
|
||||||
if (prefixSql.equals("SEL")) {
|
if (prefixSql.equals("SEL")) {
|
||||||
return STATEMENT_SELECT;
|
return STATEMENT_SELECT;
|
||||||
} else if (prefixSql.equals("INS") ||
|
} else if (prefixSql.equals("INS") ||
|
||||||
|
|||||||
Reference in New Issue
Block a user