changeset 11846:44a08df9971c libavcodec

Use new macro AV_BASE64_SIZE. Patch by James Zern, jzern google com
author cehoyos
date Mon, 07 Jun 2010 21:34:56 +0000
parents f21bbfe942d4
children 67206bbbab10
files libvpxenc.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libvpxenc.c	Mon Jun 07 11:43:12 2010 +0000
+++ b/libvpxenc.c	Mon Jun 07 21:34:56 2010 +0000
@@ -460,7 +460,7 @@
     coded_size = queue_frames(avctx, buf, buf_size, avctx->coded_frame);
 
     if (!frame && avctx->flags & CODEC_FLAG_PASS1) {
-        unsigned int b64_size = ((ctx->twopass_stats.sz + 2) / 3) * 4 + 1;
+        unsigned int b64_size = AV_BASE64_SIZE(ctx->twopass_stats.sz);
 
         avctx->stats_out = av_malloc(b64_size);
         if (!avctx->stats_out) {