Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandra Khirnova <alexandra.khirnova@gmail.com>2013-12-06 16:44:17 +0400
committerMartin Storsjö <martin@martin.st>2013-12-09 14:27:51 +0400
commit9b8d11a76ae7bca8bbb58abb822138f8b42c776c (patch)
tree702aed7eb0e0684c7a91fdac06a9981fb4333c49 /libavcodec/eatgv.c
parentd4f1188d1a662fed5347e70016da49e01563e8a8 (diff)
avcodec: Use av_reallocp where suitable
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavcodec/eatgv.c')
-rw-r--r--libavcodec/eatgv.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/libavcodec/eatgv.c b/libavcodec/eatgv.c
index 7ab18c57b0..3bc650665c 100644
--- a/libavcodec/eatgv.c
+++ b/libavcodec/eatgv.c
@@ -178,7 +178,11 @@ static int tgv_decode_inter(TgvContext *s, AVFrame *frame,
}
if (num_blocks_packed > s->num_blocks_packed) {
- s->block_codebook = av_realloc(s->block_codebook, num_blocks_packed*16);
+ int err;
+ if ((err = av_reallocp(&s->block_codebook, num_blocks_packed * 16)) < 0) {
+ s->num_blocks_packed = 0;
+ return err;
+ }
s->num_blocks_packed = num_blocks_packed;
}