Merge commit 'ac9d159015a88aa2721b271875d18482f713f354'
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 16 Sep 2013 11:25:03 +0000 (13:25 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Mon, 16 Sep 2013 11:42:20 +0000 (13:42 +0200)
* commit 'ac9d159015a88aa2721b271875d18482f713f354':
  proresdec: Properly make sure an index doesn't run past the limit

Conflicts:
libavcodec/proresdec_lgpl.c

See: 30df9789a9745d8e4b1afc10d1a983bfc8816eb9
Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavcodec/proresdec_lgpl.c

@@@ -496,8 -496,8 +496,9 @@@ static void unpack_alpha(GetBitContext 
                  dst[idx++] = alpha_val >> 6;
              else
                  dst[idx++] = (alpha_val << 2) | (alpha_val >> 6);
-             if (idx >= num_coeffs)
 -            if (idx >= num_coeffs - 1)
++            if (idx >= num_coeffs) {
                  break;
++            }
          } while (get_bits1(gb));
          val = get_bits(gb, 4);
          if (!val)