Skip to content

Commit

Permalink
ensure lane is greater than -1
Browse files Browse the repository at this point in the history
  • Loading branch information
juliooa committed Aug 3, 2018
1 parent 6297503 commit 13bda06
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ public void getLane(int lane, Rect laneRect) {
}

public int pushChildFrame(Rect outRect, int lane, int margin, Direction direction) {
if(lane >= mLanes.length)
if(lane < 0 || lane >= mLanes.length)
return 0;

final int delta;
Expand Down

0 comments on commit 13bda06

Please sign in to comment.