Fix ALL the off by one errors