Fixed a chance of getting an IndexOverflow