Revision 4c64c8e9 libavcodec/ac3dec.c

View differences:

libavcodec/ac3dec.c
1173 1173
        /* channel delta offset, len and bit allocation */
1174 1174
        for (ch = !cpl_in_use; ch <= fbw_channels; ch++) {
1175 1175
            if (s->dba_mode[ch] == DBA_NEW) {
1176
                s->dba_nsegs[ch] = get_bits(gbc, 3);
1177
                for (seg = 0; seg <= s->dba_nsegs[ch]; seg++) {
1176
                s->dba_nsegs[ch] = get_bits(gbc, 3) + 1;
1177
                for (seg = 0; seg < s->dba_nsegs[ch]; seg++) {
1178 1178
                    s->dba_offsets[ch][seg] = get_bits(gbc, 5);
1179 1179
                    s->dba_lengths[ch][seg] = get_bits(gbc, 4);
1180 1180
                    s->dba_values[ch][seg] = get_bits(gbc, 3);

Also available in: Unified diff