avcodec/cngdec: Fix integer clipping