aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/assdec.c
diff options
context:
space:
mode:
authorClément Bœsch <ubitux@gmail.com>2012-01-29 14:47:04 +0100
committerClément Bœsch <ubitux@gmail.com>2012-01-30 23:28:36 +0100
commitcc7342f712c0822c3e8f4c36fc55632c59aabac9 (patch)
tree892fbdaee5e5884d169145e590e8ff62a5f3eaac /libavcodec/assdec.c
parent7c0d30b57b5fe141df068767aad26c1c1bcc948f (diff)
downloadffmpeg-cc7342f712c0822c3e8f4c36fc55632c59aabac9.tar.gz
assdec: fix wrong alloc pointer check.
Diffstat (limited to 'libavcodec/assdec.c')
-rw-r--r--libavcodec/assdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/assdec.c b/libavcodec/assdec.c
index 087a0c839b..c5f9cab6e0 100644
--- a/libavcodec/assdec.c
+++ b/libavcodec/assdec.c
@@ -26,7 +26,7 @@
static av_cold int ass_decode_init(AVCodecContext *avctx)
{
avctx->subtitle_header = av_malloc(avctx->extradata_size);
- if (!avctx->extradata)
+ if (!avctx->subtitle_header)
return AVERROR(ENOMEM);
memcpy(avctx->subtitle_header, avctx->extradata, avctx->extradata_size);
avctx->subtitle_header_size = avctx->extradata_size;