Merge pull request #120 from bgrozev/edge-workaround

fix: Uses the correct index.
This commit is contained in:
bbaldino 2017-06-26 10:55:45 -07:00 committed by GitHub
commit c25288460d

View File

@ -81,7 +81,7 @@ public class UsernameAttribute extends Attribute
{
if (stripTrailingZeroes)
{
while (length > 0 && attributeValue[offset + length] == 0)
while (length > 0 && attributeValue[offset + length - 1] == 0)
{
length--;
}