From 784824a68c00d95dd81085483950b92203345a65 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Fri, 4 Jun 2010 01:15:41 +0000 Subject: Use AV_BASE64_SIZE() macro Originally committed as revision 23462 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/libtheoraenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libavcodec/libtheoraenc.c') diff --git a/libavcodec/libtheoraenc.c b/libavcodec/libtheoraenc.c index 2dc45a92cb..b502942718 100644 --- a/libavcodec/libtheoraenc.c +++ b/libavcodec/libtheoraenc.c @@ -101,7 +101,7 @@ static int get_stats(AVCodecContext *avctx, int eos) memcpy(h->stats + h->stats_offset, buf, bytes); h->stats_offset += bytes; } else { - int b64_size = ((h->stats_offset + 2) / 3) * 4 + 1; + int b64_size = AV_BASE64_SIZE(h->stats_offset); // libtheora generates a summary header at the end memcpy(h->stats, buf, bytes); avctx->stats_out = av_malloc(b64_size); -- cgit v1.2.3