More overflow problem fixes