exr: fix header parsing

the header in the sample provided for ticket #1306 is not parsed correctly and thus
ffmpeg tries to decode the sample instead of abording the decoding.

I tested it with two other exr samples I have - one float, one half float - and
they still decode correctly.

Signed-off-by: Jean First <jeanfirst@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Jean First 2012-05-15 16:34:58 +02:00 committed by Michael Niedermayer
parent 9225513242
commit f7985f348f
1 changed files with 1 additions and 1 deletions

View File

@ -198,7 +198,7 @@ static int decode_frame(AVCodecContext *avctx,
if (!variable_buffer_data_size)
return -1;
channel_list_end = buf + variable_buffer_data_size + 4;
channel_list_end = buf + variable_buffer_data_size;
while (channel_list_end - buf >= 19) {
int current_bits_per_color_id = -1;
int channel_index = -1;