summaryrefslogtreecommitdiff
path: root/libavcodec/proresdec2.c
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2013-05-19 01:48:39 +0200
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2013-05-19 01:48:39 +0200
commite32bbd411242658717b0dd637dd85da4c8b40437 (patch)
tree13f44010d80b4d16c49641c943bf6e07a54bac46 /libavcodec/proresdec2.c
parentc86d3a54dedc4dbf37a84a3559facb7e7ad8ef9f (diff)
downloadffmpeg-e32bbd411242658717b0dd637dd85da4c8b40437.tar.gz
proresdec2: Only try to decode alpha plane if four output planes were allocated.
Fixes a crash with MPlayer.
Diffstat (limited to 'libavcodec/proresdec2.c')
-rw-r--r--libavcodec/proresdec2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/proresdec2.c b/libavcodec/proresdec2.c
index 3073880ac2..374c5cb8ad 100644
--- a/libavcodec/proresdec2.c
+++ b/libavcodec/proresdec2.c
@@ -591,7 +591,7 @@ static int decode_slice_thread(AVCodecContext *avctx, void *arg, int jobnr, int
qmat_chroma_scaled, log2_chroma_blocks_per_mb);
}
/* decode alpha plane if available */
- if (ctx->alpha_info && dest_a && a_data_size)
+ if (ctx->alpha_info && pic->data[3] && a_data_size)
decode_slice_alpha(ctx, (uint16_t*)dest_a, luma_stride,
buf + y_data_size + u_data_size + v_data_size,
a_data_size, slice->mb_count);