Fix division by 0 on 32 bit systems