1
0
mirror of https://git.ffmpeg.org/ffmpeg.git synced 2025-03-02 02:30:58 +00:00

Prevent NULL dereferences when missing the reference frame in the xan decoder.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 19e95b8845)
This commit is contained in:
Laurent Aimar 2011-09-27 23:43:57 +02:00 committed by Michael Niedermayer
parent 23197f5467
commit 6b0565e5b8

View File

@ -222,6 +222,8 @@ static inline void xan_wc3_copy_pixel_run(XanContext *s,
palette_plane = s->current_frame.data[0];
prev_palette_plane = s->last_frame.data[0];
if (!prev_palette_plane)
prev_palette_plane = palette_plane;
stride = s->current_frame.linesize[0];
line_inc = stride - width;
curframe_index = y * stride + x;