Merge commit '9b8d11a76ae7bca8bbb58abb822138f8b42c776c'

* commit '9b8d11a76ae7bca8bbb58abb822138f8b42c776c':
  avcodec: Use av_reallocp where suitable

Conflicts:
	libavcodec/bitstream.c
	libavcodec/eatgv.c
	libavcodec/flashsv.c
	libavcodec/libtheoraenc.c
	libavcodec/libvpxenc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer
2013-12-09 20:31:29 +01:00
10 changed files with 65 additions and 77 deletions

View File

@@ -181,9 +181,10 @@ static int tgv_decode_inter(TgvContext *s, AVFrame *frame,
}
if (num_blocks_packed > s->num_blocks_packed) {
if (av_reallocp_array(&s->block_codebook, num_blocks_packed, sizeof(*s->block_codebook))) {
int err;
if ((err = av_reallocp(&s->block_codebook, num_blocks_packed * 16)) < 0) {
s->num_blocks_packed = 0;
return AVERROR(ENOMEM);
return err;
}
s->num_blocks_packed = num_blocks_packed;
}