summaryrefslogtreecommitdiff
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2011-12-20 22:06:35 +0100
committerMichael Niedermayer <michaelni@gmx.at>2011-12-20 22:23:12 +0100
commitf27930cd9a2d4970b182024a42a9f5103c942f21 (patch)
tree68ca8a0aef9034055ca6c12d23fb9f31a4979f81 /libavcodec
parent452406bd5bbf21a0da7104e6edca9c6e70636511 (diff)
indeo5: Fix null pointer dereference
Fixes Ticket803 Bug found by: Oana Stratulat Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/ivi_common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/ivi_common.c b/libavcodec/ivi_common.c
index 7f14a89f33..f240845382 100644
--- a/libavcodec/ivi_common.c
+++ b/libavcodec/ivi_common.c
@@ -611,6 +611,9 @@ void ff_ivi_output_plane(IVIPlaneDesc *plane, uint8_t *dst, int dst_pitch)
const int16_t *src = plane->bands[0].buf;
uint32_t pitch = plane->bands[0].pitch;
+ if(!src)
+ return;
+
for (y = 0; y < plane->height; y++) {
for (x = 0; x < plane->width; x++)
dst[x] = av_clip_uint8(src[x] + 128);