#2333: Fix StringIndexOutOfBoundsException in TextComponent.fromLegacy

This commit is contained in:
Gabscap
2018-01-27 15:43:33 +01:00
committed by md_5
parent aef386178a
commit c0356eb72d
2 changed files with 43 additions and 1 deletions

View File

@@ -39,7 +39,10 @@ public final class TextComponent extends BaseComponent
char c = message.charAt( i );
if ( c == ChatColor.COLOR_CHAR )
{
i++;
if ( ++i >= message.length() )
{
break;
}
c = message.charAt( i );
if ( c >= 'A' && c <= 'Z' )
{