Fix range for encoding small integers