libavcodec/alsdec.c:390: error: Integer Overflow L2
  ([0, +oo] - [0, 2147483647]):unsigned32 by call to `bitstream_skip`.

libavcodec/alsdec.c:376:9: Assignment
374.     trailer_size = bitstream_read(&bc, 32);
375.     if (header_size  == 0xFFFFFFFF)
376.         header_size  = 0;
             ^
377.     if (trailer_size == 0xFFFFFFFF)
378.         trailer_size = 0;

libavcodec/alsdec.c:380:5: Assignment
378.         trailer_size = 0;
379. 
380.     ht_size = ((int64_t)(header_size) + (int64_t)(trailer_size)) << 3;
         ^
381. 
382. 

libavcodec/alsdec.c:390:5: Call
388.         return AVERROR_PATCHWELCOME;
389. 
390.     bitstream_skip(&bc, ht_size);
         ^
391. 
392. 

libavcodec/bitstream.h:240:1: Parameter `n`
  238. 
  239. /* Skip n bits in the buffer. */
  240. static inline void bitstream_skip(BitstreamContext *bc, unsigned n)
       ^
  241. {
  242.     if (n < bc->bits_left)

libavcodec/bitstream.h:243:9: Call
  241. {
  242.     if (n < bc->bits_left)
  243.         skip_remaining(bc, n);
               ^
  244.     else {
  245.         n -= bc->bits_left;

libavcodec/bitstream.h:229:1: <LHS trace>
227. }
228. 
229. static inline void skip_remaining(BitstreamContext *bc, unsigned n)
     ^
230. {
231. #ifdef BITSTREAM_READER_LE

libavcodec/bitstream.h:229:1: Parameter `bc->bits_left`
    227. }
    228. 
    229. static inline void skip_remaining(BitstreamContext *bc, unsigned n)
         ^
    230. {
    231. #ifdef BITSTREAM_READER_LE

libavcodec/bitstream.h:229:1: <RHS trace>
227. }
228. 
229. static inline void skip_remaining(BitstreamContext *bc, unsigned n)
     ^
230. {
231. #ifdef BITSTREAM_READER_LE

libavcodec/bitstream.h:229:1: Parameter `n`
    227. }
    228. 
    229. static inline void skip_remaining(BitstreamContext *bc, unsigned n)
         ^
    230. {
    231. #ifdef BITSTREAM_READER_LE

libavcodec/bitstream.h:236:5: Binary operation: ([0, +oo] - [0, 2147483647]):unsigned32 by call to `bitstream_skip` 
    234.     bc->bits <<= n;
    235. #endif
    236.     bc->bits_left -= n;
             ^
    237. }
    238. 

static inline void skip_remaining(BitstreamContext *bc, unsigned n)
{
#ifdef BITSTREAM_READER_LE
    bc->bits >>= n;
#else
    bc->bits <<= n;
#endif
    bc->bits_left -= n;
}
["static av_cold int read_specific_config(ALSDecContext *ctx)\n{\n    BitstreamContext bc;\n    uint64_t ht_size;\n    int i, config_offset;\n    MPEG4AudioConfig m4ac;\n    ALSSpecificConfig *sconf = &ctx->sconf;\n    AVCodecContext *avctx    = ctx->avctx;\n    uint32_t als_id, header_size, trailer_size;\n    bitstream_init8(&bc, avctx->extradata, avctx->extradata_size);\n    config_offset = avpriv_mpeg4audio_get_config(&m4ac, avctx->extradata,\n                                                 avctx->extradata_size * 8, 1);\n    if (config_offset < 0)\n        return AVERROR_INVALIDDATA;\n    bitstream_skip(&bc, config_offset);\n    if (bitstream_bits_left(&bc) < (30 << 3))\n        return AVERROR_INVALIDDATA;\n    als_id                      = bitstream_read(&bc, 32);\n    avctx->sample_rate          = m4ac.sample_rate;\n    bitstream_skip(&bc, 32);\n    sconf->samples              = bitstream_read(&bc, 32);\n    avctx->channels             = m4ac.channels;\n    bitstream_skip(&bc, 16);\n    bitstream_skip(&bc, 3);\n    sconf->resolution           = bitstream_read(&bc, 3);\n    sconf->floating             = bitstream_read_bit(&bc);\n    sconf->msb_first            = bitstream_read_bit(&bc);\n    sconf->frame_length         = bitstream_read(&bc, 16) + 1;\n    sconf->ra_distance          = bitstream_read(&bc, 8);\n    sconf->ra_flag              = bitstream_read(&bc, 2);\n    sconf->adapt_order          = bitstream_read_bit(&bc);\n    sconf->coef_table           = bitstream_read(&bc, 2);\n    sconf->long_term_prediction = bitstream_read_bit(&bc);\n    sconf->max_order            = bitstream_read(&bc, 10);\n    sconf->block_switching      = bitstream_read(&bc, 2);\n    sconf->bgmc                 = bitstream_read_bit(&bc);\n    sconf->sb_part              = bitstream_read_bit(&bc);\n    sconf->joint_stereo         = bitstream_read_bit(&bc);\n    sconf->mc_coding            = bitstream_read_bit(&bc);\n    sconf->chan_config          = bitstream_read_bit(&bc);\n    sconf->chan_sort            = bitstream_read_bit(&bc);\n    sconf->crc_enabled          = bitstream_read_bit(&bc);\n    sconf->rlslms               = bitstream_read_bit(&bc);\n    bitstream_skip(&bc, 5);\n    bitstream_skip(&bc, 1);\n    if (als_id != MKBETAG('A','L','S','\\0'))\n        return AVERROR_INVALIDDATA;\n    ctx->cur_frame_length = sconf->frame_length;\n    if (sconf->chan_config)\n        sconf->chan_config_info = bitstream_read(&bc, 16);\n    if (sconf->chan_sort && avctx->channels > 1) {\n        int chan_pos_bits = av_ceil_log2(avctx->channels);\n        int bits_needed  = avctx->channels * chan_pos_bits + 7;\n        if (bitstream_bits_left(&bc) < bits_needed)\n            return AVERROR_INVALIDDATA;\n        if (!(sconf->chan_pos = av_malloc(avctx->channels * sizeof(*sconf->chan_pos))))\n            return AVERROR(ENOMEM);\n        for (i = 0; i < avctx->channels; i++)\n            sconf->chan_pos[i] = bitstream_read(&bc, chan_pos_bits);\n        bitstream_align(&bc);\n    } else {\n        sconf->chan_sort = 0;\n    }\n    if (bitstream_bits_left(&bc) < 64)\n        return AVERROR_INVALIDDATA;\n    header_size  = bitstream_read(&bc, 32);\n    trailer_size = bitstream_read(&bc, 32);\n    if (header_size  == 0xFFFFFFFF)\n        header_size  = 0;\n    if (trailer_size == 0xFFFFFFFF)\n        trailer_size = 0;\n    ht_size = ((int64_t)(header_size) + (int64_t)(trailer_size)) << 3;\n    if (bitstream_bits_left(&bc) < ht_size)\n        return AVERROR_INVALIDDATA;\n    if (ht_size > INT32_MAX)\n        return AVERROR_PATCHWELCOME;\n    bitstream_skip(&bc, ht_size);\n    if (sconf->crc_enabled) {\n        if (bitstream_bits_left(&bc) < 32)\n            return AVERROR_INVALIDDATA;\n        if (avctx->err_recognition & AV_EF_CRCCHECK) {\n            ctx->crc_table = av_crc_get_table(AV_CRC_32_IEEE_LE);\n            ctx->crc       = 0xFFFFFFFF;\n            ctx->crc_org   = ~bitstream_read(&bc, 32);\n        } else\n            bitstream_skip(&bc, 32);\n    }\n    dprint_specific_config(ctx);\n    return 0;\n}", 'static inline void bitstream_skip(BitstreamContext *bc, unsigned n)\n{\n    if (n < bc->bits_left)\n        skip_remaining(bc, n);\n    else {\n        n -= bc->bits_left;\n        bc->bits      = 0;\n        bc->bits_left = 0;\n        if (n >= 64) {\n            unsigned skip = n / 8;\n            n -= skip * 8;\n            bc->ptr += skip;\n        }\n        refill_64(bc);\n        if (n)\n            skip_remaining(bc, n);\n    }\n}', 'static inline void skip_remaining(BitstreamContext *bc, unsigned n)\n{\n#ifdef BITSTREAM_READER_LE\n    bc->bits >>= n;\n#else\n    bc->bits <<= n;\n#endif\n    bc->bits_left -= n;\n}']