aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/qdm2.c
diff options
context:
space:
mode:
authorBenjamin Larsson <banan@ludd.ltu.se>2008-07-19 15:48:53 +0000
committerBenjamin Larsson <banan@ludd.ltu.se>2008-07-19 15:48:53 +0000
commitf7dbf86d935376d622db7ada1a3fe1bf64e8e8b0 (patch)
tree93ce75bfefe04cc92b7f1308e391dac2d6b88e13 /libavcodec/qdm2.c
parent9f59e608d2355f098f667bacba31424d80ba57a4 (diff)
downloadffmpeg-f7dbf86d935376d622db7ada1a3fe1bf64e8e8b0.tar.gz
Fix for possible null pointer dereferencing, closes Coverity report 68 run 2.
Originally committed as revision 14305 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/qdm2.c')
-rw-r--r--libavcodec/qdm2.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/qdm2.c b/libavcodec/qdm2.c
index 87bcb47adc..e4a7878a8c 100644
--- a/libavcodec/qdm2.c
+++ b/libavcodec/qdm2.c
@@ -1452,6 +1452,9 @@ static void qdm2_decode_fft_packets (QDM2Context *q)
max = min;
/* check for errors (?) */
+ if (!packet)
+ return;
+
if (i == 0 && (packet->type < 16 || packet->type >= 48 || fft_subpackets[packet->type - 16]))
return;