Skip to content

Commit 20a1ebb

Browse files
committed
Merge pull request #13 from garydgregory/turkish-fix
Fix for classic toUpperCase gotcha when locale is Turkish
2 parents 9bab505 + 6322936 commit 20a1ebb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

jansi/src/main/java/org/fusesource/jansi/AnsiRenderer.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
package org.fusesource.jansi;
1818

19+
import java.util.Locale;
20+
1921
import org.fusesource.jansi.Ansi.Attribute;
2022
import org.fusesource.jansi.Ansi.Color;
2123

@@ -102,7 +104,7 @@ static public String render(final String input) throws IllegalArgumentException
102104
static private String render(final String text, final String... codes) {
103105
Ansi ansi = Ansi.ansi();
104106
for (String name : codes) {
105-
Code code = Code.valueOf(name.toUpperCase());
107+
Code code = Code.valueOf(name.toUpperCase(Locale.ENGLISH));
106108

107109
if (code.isColor()) {
108110
if (code.isBackground()) {

0 commit comments

Comments
 (0)