From 6c35b4dee3da7caba822d5b1af683c1f7922dc7d Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Sun, 25 Jun 2006 21:22:25 +0000 Subject: [PATCH] 10l Originally committed as revision 5527 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/flacenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/flacenc.c b/libavcodec/flacenc.c index d88b11d4c4..29d3ce1fd4 100644 --- a/libavcodec/flacenc.c +++ b/libavcodec/flacenc.c @@ -331,7 +331,7 @@ write_utf8(PutBitContext *pb, uint32_t val) return; } - bytes= (av_log2(val)-1) / 5; + bytes= (av_log2(val)+4) / 5; shift = (bytes - 1) * 6; put_bits(pb, 8, (256 - (256>>bytes)) | (val >> shift)); while(shift >= 6){