Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for classic toUpperCase gotcha when locale is Turkish #13

Merged
merged 1 commit into from
Apr 6, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion jansi/src/main/java/org/fusesource/jansi/AnsiRenderer.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@

package org.fusesource.jansi;

import java.util.Locale;

import org.fusesource.jansi.Ansi.Attribute;
import org.fusesource.jansi.Ansi.Color;

Expand Down Expand Up @@ -102,7 +104,7 @@ static public String render(final String input) throws IllegalArgumentException
static private String render(final String text, final String... codes) {
Ansi ansi = Ansi.ansi();
for (String name : codes) {
Code code = Code.valueOf(name.toUpperCase());
Code code = Code.valueOf(name.toUpperCase(Locale.ENGLISH));

if (code.isColor()) {
if (code.isBackground()) {
Expand Down