summaryrefslogtreecommitdiff
path: root/libavcodec/svq3.c
diff options
context:
space:
mode:
authorDustin Brody <libav@parsoma.net>2011-08-12 12:05:46 -0400
committerAnton Khirnov <anton@khirnov.net>2011-08-15 21:26:34 +0200
commita3e215cdc964fdecf9c5642c2f84ff963e35170a (patch)
treec5bad90eea1c376f6d6227a9aec3e415122bfdc5 /libavcodec/svq3.c
parentcc73511e8e81b2e1454f406acb71da9fd1c60d32 (diff)
svq3: propagate codec memory allocation failure in context init
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Diffstat (limited to 'libavcodec/svq3.c')
-rw-r--r--libavcodec/svq3.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index f6f9fc17fe..3cd95ba594 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -924,7 +924,10 @@ static av_cold int svq3_decode_init(AVCodecContext *avctx)
h->b_stride = 4*s->mb_width;
- ff_h264_alloc_tables(h);
+ if (ff_h264_alloc_tables(h) < 0) {
+ av_log(avctx, AV_LOG_ERROR, "svq3 memory allocation failed\n");
+ return AVERROR(ENOMEM);
+ }
}
return 0;