summaryrefslogtreecommitdiff
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-09-16 13:25:03 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-09-16 13:42:20 +0200
commite0fcd0294e2f6cc9a3ade974a561be54c9efbc31 (patch)
treedff29a73a360ba80397e09ec3855746c87e55fde /libavcodec
parent18e0dd05df136ce049b9827367bbf680a2c12d89 (diff)
parentac9d159015a88aa2721b271875d18482f713f354 (diff)
Merge commit 'ac9d159015a88aa2721b271875d18482f713f354'
* 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>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/proresdec_lgpl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/proresdec_lgpl.c b/libavcodec/proresdec_lgpl.c
index bf61a38b3d..2fef2c6e43 100644
--- a/libavcodec/proresdec_lgpl.c
+++ b/libavcodec/proresdec_lgpl.c
@@ -496,8 +496,9 @@ static void unpack_alpha(GetBitContext *gb, uint16_t *dst, int num_coeffs,
dst[idx++] = alpha_val >> 6;
else
dst[idx++] = (alpha_val << 2) | (alpha_val >> 6);
- if (idx >= num_coeffs)
+ if (idx >= num_coeffs) {
break;
+ }
} while (get_bits1(gb));
val = get_bits(gb, 4);
if (!val)