Skip to content

Commit

Permalink
Fix out of range bug in set initial index. Shame!
Browse files Browse the repository at this point in the history
  • Loading branch information
roxrook committed Sep 21, 2015
1 parent 5791e11 commit a88fc58
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ private void preComputeDrawingPosition() {
}

public void setInitialIndex(int index) {
if (index < 0 || index > rangeCount) {
if (index < 0 || index >= rangeCount) {
throw new IllegalArgumentException("Attempted to set index=" + index + " out of range [0," + rangeCount + "]");
}
currentIndex = index;
Expand Down

0 comments on commit a88fc58

Please sign in to comment.